diff --git a/.github/workflows/git-town.yml b/.github/workflows/git-town.yml new file mode 100644 index 00000000..0c1ef525 --- /dev/null +++ b/.github/workflows/git-town.yml @@ -0,0 +1,19 @@ +name: Git Town + +on: + pull_request: + +jobs: + git-town: + name: Display the branch stack + runs-on: ubuntu-slim + + if: ${{ !startsWith(github.head_ref, 'release-please--') }} + + permissions: + contents: read + pull-requests: write + + steps: + - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 + - uses: git-town/action@e483957e6d4827e62413707d4c8f9678c9dc19f1 # v1.3.2 diff --git a/.mise/config.toml b/.mise/config.toml new file mode 100644 index 00000000..848e57d3 --- /dev/null +++ b/.mise/config.toml @@ -0,0 +1,7 @@ +[tools] +node = "25.4.0" +pnpm = "10.28.1" +restic = "0.18.0" + +gh = "2.25.0" +"github:git-town/git-town" = "22.4.0" diff --git a/default.nix b/default.nix new file mode 100644 index 00000000..27b8d667 --- /dev/null +++ b/default.nix @@ -0,0 +1,54 @@ +{ pkgs ? import (fetchTarball { + url = "https://github.com/NixOS/nixpkgs/archive/77ef7a29d276c6d8303aece3444d61118ef71ac2.tar.gz"; + sha256 = "0pm4l48jq8plzrrrisimahxqlcpx7qqq9c99hylmf7p3zlc3phsy"; + }) {}, + + # Playwright v1.57.0 + unstablePkgs ? import (fetchTarball { + url = "https://github.com/NixOS/nixpkgs/archive/145b67bd0bd4e075f981c1c2b81155d9e2982de2.tar.gz"; + sha256 = "152qwxacs6lw1dskn21985qly8ipjzwpsvicy7inzh3hhma603gg"; + }) {}, +}: + +let + nix-ld-libs = pkgs.buildEnv { + name = "nix-ld-libs"; + paths = with pkgs; [ + stdenv.cc.cc.lib + zlib + openssl + ]; + }; + +in pkgs.mkShell { + packages = with pkgs; [ + mise + lsof + pkg-config + openssl.dev + (writeShellScriptBin "fish" '' + exec ${pkgs.fish}/bin/fish -C 'mise activate fish | source' "$@" + '') + ]; + + shellHook = '' + export NIX_LD="${pkgs.stdenv.cc.libc}/lib/ld-linux-x86-64.so.2" + export NIX_LD_LIBRARY_PATH="${nix-ld-libs}/lib" + + export MISE_NODE_COMPILE=false + eval "$(mise activate bash)" + + export PLAYWRIGHT_BROWSERS_PATH=${unstablePkgs.playwright-driver.browsers} + export PLAYWRIGHT_SKIP_VALIDATE_HOST_REQUIREMENTS=true + + playwrightNpmVersion="$(npm show @playwright/test version)" + echo "❄️ Playwright nix version: ${unstablePkgs.playwright.version}" + echo "📦 Playwright npm version: $playwrightNpmVersion" + + if [ "${unstablePkgs.playwright.version}" != "$playwrightNpmVersion" ]; then + echo "❌ Playwright versions in nix and npm are not the same!" + else + echo "✅ Playwright versions in nix and npm are the same" + fi + ''; +} \ No newline at end of file diff --git a/git-town.toml b/git-town.toml new file mode 100644 index 00000000..65a40966 --- /dev/null +++ b/git-town.toml @@ -0,0 +1,8 @@ +# See https://www.git-town.com/configuration-file for details + +[branches] +main = "main" + +[hosting] +forge-type = "github" +github-connector = "gh"