diff --git a/.envrc b/.envrc new file mode 100644 index 00000000..8392d159 --- /dev/null +++ b/.envrc @@ -0,0 +1 @@ +use flake \ No newline at end of file diff --git a/.github/workflows/deploy-qa.yml b/.github/workflows/deploy-qa.yml index 7000ddb4..063e7cf5 100644 --- a/.github/workflows/deploy-qa.yml +++ b/.github/workflows/deploy-qa.yml @@ -9,7 +9,7 @@ on: - README.md env: BRANCH_NAME: '${{ github.event.inputs.branch_name || github.head_ref || github.ref_name }}' - NODE_VERSION: 16 + NODE_VERSION: 18 JAVA_VERSION: 11 JAVA_DISTRIBUTION: 'adopt' diff --git a/.github/workflows/gate-keep.yml b/.github/workflows/gate-keep.yml index 8125a501..09fab731 100644 --- a/.github/workflows/gate-keep.yml +++ b/.github/workflows/gate-keep.yml @@ -2,7 +2,7 @@ name: Gate Keeping on: push: env: - NODE_VERSION: 16 + NODE_VERSION: 18 JAVA_VERSION: 11 JAVA_DISTRIBUTION: 'adopt' diff --git a/.gitignore b/.gitignore index 6a8a90b5..305c9c75 100644 --- a/.gitignore +++ b/.gitignore @@ -35,4 +35,5 @@ dist dev .nyc_output test-results.json -.idea/ \ No newline at end of file +.idea/ +.direnv/ diff --git a/flake.lock b/flake.lock new file mode 100644 index 00000000..2df95f3b --- /dev/null +++ b/flake.lock @@ -0,0 +1,61 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1730602179, + "narHash": "sha256-efgLzQAWSzJuCLiCaQUCDu4NudNlHdg2NzGLX5GYaEY=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "3c2f1c4ca372622cb2f9de8016c9a0b1cbd0f37c", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-24.05", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs", + "utils": "utils" + } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "utils": { + "inputs": { + "systems": "systems" + }, + "locked": { + "lastModified": 1726560853, + "narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 00000000..576dc94c --- /dev/null +++ b/flake.nix @@ -0,0 +1,29 @@ +{ + description = "web-branch-deep-linking-attribution flake"; + + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05"; + utils.url = "github:numtide/flake-utils"; + }; + + outputs = { self, nixpkgs, utils }: + utils.lib.eachDefaultSystem (system: + let + pkgs = nixpkgs.legacyPackages.${system}; + nodejs = pkgs.nodejs-18_x; + in + { + devShell = pkgs.mkShell { + nativeBuildInputs = [ + nodejs + ]; + shellHook = '' + if [ -f $HOME/.config/bin/setup-webstorm-sdk ] && [ -f ./.idea/workspace.xml ]; then + $HOME/.config/bin/setup-webstorm-sdk || echo "setup-webstorm-sdk failed" + fi + ''; + }; + formatter = pkgs.nixpkgs-fmt; + } + ); +}