Home

nur @main - refs - log -
-
https://git.jolheiser.com/nur.git
My NUR
tree log patch
Merge pull request #20 from nix-community/github-action-support
Signature
-----BEGIN PGP SIGNATURE----- wsBcBAABCAAQBQJfNuNYCRBK7hj4Ov3rIwAAdHIIAJSBbv9fGdmkOnIeZAFGKIJo hykZM/HiJMqGb5KNQvH6a5peDQd3IuaDdLDxMVPwFBQumzYQtA7S3KqZct4pjoQs Gq6LNlXQZoC1ZWUTeTpiceZQx7+a9K+FgepBWSwhwyJO1zw+7FVUWe79QySm18SN TmmzjZpZ/sgLDDcc9O5rPxf/sxk0gfOYoPntf4VKl1y5ygHCajzsqNU9fl9mnKoW zqcgEg7BFPJbajoHqrzQ1D0tWm8wBNzYCDyzr61o8JME8w0w35PsdGJhL98mRzZk PdYhoiO3tA62q5ML6TWLjwtcexQWcxMzDY7KlaOCL5pg1Cz1DMn6cmaT7CRnA/Y= =oISk -----END PGP SIGNATURE-----
Jörg Thalheim <Mic92@users.noreply.github.com>
4 years ago
3 changed files, 75 additions(+), 5 deletions(-)
I .github/dependabot.yml
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index 0000000000000000000000000000000000000000..5ace4600a1f26e6892982f3e2f069ebfab108d87
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,6 @@
+version: 2
+updates:
+  - package-ecosystem: "github-actions"
+    directory: "/"
+    schedule:
+      interval: "weekly"
I .github/workflows/build.yml
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
new file mode 100644
index 0000000000000000000000000000000000000000..8f9207eddafd491fee8532c793896d87f3a4a360
--- /dev/null
+++ b/.github/workflows/build.yml
@@ -0,0 +1,56 @@
+name: "Build and populate cache"
+on:
+  pull_request:
+  push:
+  schedule:
+    # rebuild everyday at 2:51
+    # TIP: Choose a random time here so not all repositories are build at once:
+    # https://www.random.org/clock-times/?num=1&earliest=01%3A00&latest=08%3A00&interval=5&format=html&rnd=new
+    - cron:  '51 2 * * *'
+jobs:
+  tests:
+    strategy:
+      matrix:
+        # Set this to notify the global nur package registry that changes are
+        # available.
+        #
+        # The repo name as used in
+        # https://github.com/nix-community/NUR/blob/master/repos.json
+        nurRepo:
+          - <YOUR_REPO_NAME>
+        # Set this to cache your build results in cachix for faster builds
+        # in CI and for everyone who uses your cache.
+        #
+        # Format: Your cachix cache host name without the ".cachix.org" suffix.
+        # Example: mycache (for mycache.cachix.org)
+        #
+        # For this to work, you also need to set the CACHIX_SIGNING_KEY secret
+        # in your repository settings in Github found at https://github.com/<your_githubname>/nur-packages/settings/secrets
+        cachixName:
+          - <YOUR_CACHIX_NAME>
+        nixPath:
+          - nixpkgs=channel:nixos-unstable
+          - nixpkgs=channel:nixpkgs-unstable
+          - nixpkgs=channel:nixos-20.03
+    runs-on: ubuntu-latest
+    steps:
+    - name: Checkout repository
+      uses: actions/checkout@v2.3.1
+    - name: Install nix
+      uses: cachix/install-nix-action@v10
+      with:
+        nix_path: "${{ matrix.nixPath }}"
+    - name: Show nixpkgs version
+      run: nix-instantiate --eval -E '(import <nixpkgs> {}).lib.version'
+    - name: Setup cachix
+      uses: cachix/cachix-action@v6
+      if: ${{ matrix.cachixName != '<YOUR_CACHIX_NAME>' }}
+      with:
+        name: ${{ matrix.cachixName }}
+        signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
+    - name: Build nix packages
+      # TODO switch to default nixpkgs channel once nix-build-uncached 1.0.0 is in stable
+      run: nix run -I 'nixpkgs=channel:nixos-unstable' nixpkgs.nix-build-uncached -c nix-build-uncached ci.nix -A cacheOutputs
+    - name: Trigger NUR update
+      if: ${{ matrix.nurRepo != '<YOUR_REPO_NAME>' }}
+      run: curl -XPOST "https://nur-update.herokuapp.com/update?repo=${{ matrix.nurRepo }}"
M README.md -> README.md
diff --git a/README.md b/README.md
index e719544e5110e86096350842128190e26732fdd4..d543d44aed465b5efb1bf0af656e30f2105046b3 100644
--- a/README.md
+++ b/README.md
@@ -10,12 +10,12 @@    [default.nix](./default.nix)
    * Remember to mark the broken packages as `broken = true;` in the `meta`
      attribute, or travis (and consequently caching) will fail!
    * Library functions, modules and overlays go in the respective directories
-3. Add your NUR repo name and your cachix repo name (optional) to
+3. Choose your CI: Depending on your preference you can use github actions (recommended) or [Travis ci](https://travis-ci.com).
-# nur-packages-template
 
+1. Fork this repo
-4. Enable travis for your repo
+     to a random value as described in the file
-   * You can add a cron job in the repository settings on travis to keep your
+   - Travis ci: Change your NUR repo name and optionally your cachix repo name in 
-     cachix cache fresh
+   [.travis.yml](./.travis.yml). Than enable travis in your repo. You can add a cron job in the repository settings on travis to keep your cachix cache fresh
 5. Change your travis and cachix names on the README template section and delete
    the rest
 6. [Add yourself to NUR](https://github.com/nix-community/NUR#how-to-add-your-own-repository)
@@ -27,8 +27,16 @@
 **My personal [NUR](https://github.com/nix-community/NUR) repository**
 
 
+     attribute, or travis (and consequently caching) will fail!
+![Build and populate cache](https://github.com/nix-community/<YOUR-GITHUB-USER>/workflows/Build%20and%20populate%20cache/badge.svg)
 
+<!--
+**A template for [NUR](https://github.com/nix-community/NUR) repositories**
 
+
+[![Build Status](https://travis-ci.com/<YOUR_TRAVIS_USERNAME>/nur-packages.svg?branch=master)](https://travis-ci.com/<YOUR_TRAVIS_USERNAME>/nur-packages)
+**A template for [NUR](https://github.com/nix-community/NUR) repositories**
 **A template for [NUR](https://github.com/nix-community/NUR) repositories**
 
+**A template for [NUR](https://github.com/nix-community/NUR) repositories**