From 7f56a6568cb79a72b5b99cb860a934753f37cbb1 Mon Sep 17 00:00:00 2001 From: Robert Masen Date: Sat, 27 Apr 2024 15:40:27 -0500 Subject: [PATCH] chore: General Cleanup - Remove dead features - Remove dead crates - Configure CI on PRs instead of push --- .github/workflows/rust.yml | 6 +++--- .gitignore | 4 +--- Cargo.toml | 7 ------- crates/derive_as_concrete/.gitignore | 3 --- crates/derive_as_concrete/Cargo.toml | 14 -------------- crates/derive_as_concrete/src/lib.rs | 21 --------------------- package.json | 5 ----- 7 files changed, 4 insertions(+), 56 deletions(-) delete mode 100644 crates/derive_as_concrete/.gitignore delete mode 100644 crates/derive_as_concrete/Cargo.toml delete mode 100644 crates/derive_as_concrete/src/lib.rs delete mode 100644 package.json diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index f343b1f..86e49cc 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -1,12 +1,12 @@ name: Rust -on: [push] +on: + pull_request: + workflow_dispatch: jobs: build: - runs-on: ubuntu-latest - steps: - uses: actions/checkout@v3 - name: fmt check diff --git a/.gitignore b/.gitignore index f9dac90..51e3f37 100644 --- a/.gitignore +++ b/.gitignore @@ -2,10 +2,8 @@ **/*.rs.bk Cargo.lock .vscode/* -/node_modules *.es.json *.rs.json *.js.json *.log -package-lock.json -*.ron \ No newline at end of file +*.ron diff --git a/Cargo.toml b/Cargo.toml index 805458b..395e044 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,10 +8,3 @@ repository = "https://github.com/rusty-ecma/resast" license = "MIT" keywords = ["JavaScript", "parsing", "JS", "ES", "ECMA"] categories = ["parsing", "text-processing", "web-programming"] - -[dependencies] -serde = { version = "1", optional = true, features = ["derive"] } - -[features] -default = [] -serde = ["dep:serde"] diff --git a/crates/derive_as_concrete/.gitignore b/crates/derive_as_concrete/.gitignore deleted file mode 100644 index 6936990..0000000 --- a/crates/derive_as_concrete/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/target -**/*.rs.bk -Cargo.lock diff --git a/crates/derive_as_concrete/Cargo.toml b/crates/derive_as_concrete/Cargo.toml deleted file mode 100644 index a2b8412..0000000 --- a/crates/derive_as_concrete/Cargo.toml +++ /dev/null @@ -1,14 +0,0 @@ -[package] -name = "derive_as_concrete" -version = "0.1.0" -authors = ["rmasen"] -edition = "2018" - - -[dependencies] -quote = "0.6" -proc-macro2 = "0.4" -syn = { version = "0.15", features = ["full"] } - -[lib] -proc-macro = true \ No newline at end of file diff --git a/crates/derive_as_concrete/src/lib.rs b/crates/derive_as_concrete/src/lib.rs deleted file mode 100644 index ab3424a..0000000 --- a/crates/derive_as_concrete/src/lib.rs +++ /dev/null @@ -1,21 +0,0 @@ -extern crate proc_macro; -use proc_macro::TokenStream; -use quote::quote; - -#[proc_macro_derive(AsConcrete)] -pub fn as_concrete(input: TokenStream) -> TokenStream { - let input = syn::parse(input).unwrap(); - impl_as_concrete(&input) -} - -fn impl_as_concrete(ast: &syn::DeriveInput) -> TokenStream { - let name = &ast.ident; - let gen = quote! { - impl AsConcrete<#name> for #name { - fn as_concrete(&self) -> #name { - self.clone() - } - } - }; - gen.into() -} \ No newline at end of file diff --git a/package.json b/package.json deleted file mode 100644 index 64eb887..0000000 --- a/package.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "dependencies": { - "esprima": "^4.0.1" - } -}