Skip to content

Commit 96df9ef

Browse files
committed
.github: init workflows
1 parent 1bc6f63 commit 96df9ef

File tree

7 files changed

+227
-0
lines changed

7 files changed

+227
-0
lines changed

.github/CODEOWNERS

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Lines starting with '#' are comments.
2+
# Each line is a file pattern followed by one or more owners.
3+
# Order is important. The last matching pattern has the most precedence.
4+
5+
# These owners will be the default owners for everything in the repo.
6+
* @khaneliman

.github/dependabot.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "github-actions"
4+
directory: "/"
5+
schedule:
6+
interval: "daily"
7+
commit-message:
8+
# Prefix all commit messages with "npm: "
9+
prefix: ".github"

.github/labeler.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
Flake-Modules:
2+
- changed-files:
3+
- any-glob-to-any-file: flake-modules/**/*
4+
Modules:
5+
- changed-files:
6+
- any-glob-to-any-file: modules/**/*
7+
Library:
8+
- changed-files:
9+
- any-glob-to-any-file: lib/**/*
10+
Overlays:
11+
- changed-files:
12+
- any-glob-to-any-file: overlays/**/*
13+
Packages:
14+
- changed-files:
15+
- any-glob-to-any-file: packages/**/*
16+
GitHub-Action:
17+
- changed-files:
18+
- any-glob-to-any-file: .github/workflows/*

.github/settings.yml

Lines changed: 122 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,122 @@
1+
repository:
2+
# See https://developer.github.com/v3/repos/#edit for all available settings.
3+
4+
# The name of the repository. Changing this will rename the repository
5+
name: khanelivim
6+
# A short description of the repository that will show up on GitHub
7+
description: Nixvim neovim flake.
8+
# A URL with more information about the repository
9+
homepage: ""
10+
# A comma-separated list of topics to set on the repository
11+
topics: "neovim,nixos,unstable,nixvim,nix"
12+
# Either `true` to make the repository private, or `false` to make it public.
13+
private: false
14+
# Either `true` to enable issues for this repository, `false` to disable them.
15+
has_issues: true
16+
# Either `true` to enable projects for this repository, or `false` to disable them.
17+
# If projects are disabled for the organization, passing `true` will cause an API error.
18+
has_projects: true
19+
# Either `true` to enable the wiki for this repository, `false` to disable it.
20+
has_wiki: true
21+
# Either `true` to enable downloads for this repository, `false` to disable them.
22+
has_downloads: false
23+
# Updates the default branch for this repository.
24+
default_branch: main
25+
# Either `true` to allow squash-merging pull requests, or `false` to prevent
26+
# squash-merging.
27+
allow_squash_merge: true
28+
# Either `true` to allow merging pull requests with a merge commit, or `false`
29+
# to prevent merging pull requests with merge commits.
30+
allow_merge_commit: true
31+
# Either `true` to allow rebase-merging pull requests, or `false` to prevent
32+
# rebase-merging.
33+
allow_rebase_merge: true
34+
# Either `true` to enable automatic deletion of branches on merge, or `false` to disable
35+
delete_branch_on_merge: true
36+
# Either `true` to enable automated security fixes, or `false` to disable
37+
# automated security fixes.
38+
enable_automated_security_fixes: true
39+
# Either `true` to enable vulnerability alerts, or `false` to disable
40+
# vulnerability alerts.
41+
enable_vulnerability_alerts: true
42+
# Labels: define labels for Issues and Pull Requests
43+
#
44+
labels:
45+
# NOTE: leave that up to the https://github.com/numtide/.github repo
46+
# - name: bug
47+
# color: CC0000
48+
# description: An issue with the system 🐛.
49+
50+
# - name: feature
51+
# # If including a `#`, make sure to wrap it with quotes!
52+
# color: '#336699'
53+
# description: New functionality.
54+
55+
# - name: Help Wanted
56+
# # Provide a new name to rename an existing label
57+
# new_name: first-timers-only
58+
59+
# Milestones: define milestones for Issues and Pull Requests
60+
milestones:
61+
# - title: milestone-title
62+
# description: milestone-description
63+
# # The state of the milestone. Either `open` or `closed`
64+
# state: open
65+
66+
# Collaborators: give specific users access to this repository.
67+
# See https://docs.github.com/en/rest/reference/repos#add-a-repository-collaborator for available options
68+
collaborators:
69+
# Note: `permission` is only valid on organization-owned repositories.
70+
# The permission to grant the collaborator. Can be one of:
71+
# * `pull` - can pull, but not push to or administer this repository.
72+
# * `push` - can pull and push, but not administer this repository.
73+
# * `admin` - can pull, push and administer this repository.
74+
# * `maintain` - Recommended for project managers who need to manage the repository without access to sensitive or destructive actions.
75+
# * `triage` - Recommended for contributors who need to proactively manage issues and pull requests without write access.
76+
# permission: push
77+
78+
# See https://docs.github.com/en/rest/reference/teams#add-or-update-team-repository-permissions for available options
79+
teams:
80+
# The permission to grant the team. Can be one of:
81+
# * `pull` - can pull, but not push to or administer this repository.
82+
# * `push` - can pull and push, but not administer this repository.
83+
# * `admin` - can pull, push and administer this repository.
84+
# * `maintain` - Recommended for project managers who need to manage the repository without access to sensitive or destructive actions.
85+
# * `triage` - Recommended for contributors who need to proactively manage issues and pull requests without write access.
86+
# permission: maintain
87+
branches:
88+
- name: main
89+
# https://docs.github.com/en/rest/reference/repos#update-branch-protection
90+
# Branch Protection settings. Set to null to disable
91+
protection:
92+
# Required. Require at least one approving review on a pull request, before merging. Set to null to disable.
93+
required_pull_request_reviews:
94+
# # The number of approvals required. (1-6)
95+
required_approving_review_count: 1
96+
# # Dismiss approved reviews automatically when a new commit is pushed.
97+
dismiss_stale_reviews: true
98+
# # Blocks merge until code owners have reviewed.
99+
require_code_owner_reviews: true
100+
# # Specify which users and teams can dismiss pull request reviews. Pass an empty dismissal_restrictions object to disable. User and team dismissal_restrictions are only available for organization-owned repositories. Omit this parameter for personal repositories.
101+
# dismissal_restrictions:
102+
# users: []
103+
# teams: []
104+
# Required. Require status checks to pass before merging. Set to null to disable
105+
required_status_checks:
106+
# Required. Require branches to be up to date before merging.
107+
strict: true
108+
# Required. The list of status checks to require in order to merge into this branch
109+
contexts: []
110+
# Required. Enforce all configured restrictions for administrators. Set to true to enforce required status checks for repository administrators. Set to null to disable.
111+
enforce_admins: false
112+
required_linear_history: true
113+
required_conversation_resolution: true
114+
required_signatures: true
115+
# Required. Restrict who can push to this branch. Team and user restrictions are only available for organization-owned repositories. Set to null to disable.
116+
restrictions:
117+
# apps: []
118+
# users: []
119+
# teams: []
120+
actions:
121+
default_workflow_permissions: "write"
122+
can_approve_pull_request_reviews": true

.github/workflows/check.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Check
2+
on: [push, pull_request, workflow_dispatch]
3+
jobs:
4+
checks:
5+
name: Check expressions on ${{ matrix.arch }}
6+
runs-on: ${{ matrix.os }}
7+
strategy:
8+
fail-fast: false
9+
matrix:
10+
os: [ubuntu-latest]
11+
arch: [x86_64-linux, aarch64-darwin]
12+
if: github.ref == 'refs/heads/main'
13+
steps:
14+
- uses: actions/checkout@v4
15+
- name: Check Nix flake inputs
16+
uses: DeterminateSystems/flake-checker-action@v9
17+
- uses: cachix/install-nix-action@v30
18+
with:
19+
install_url: https://nixos.org/nix/install
20+
extra_nix_config: |
21+
auto-optimise-store = true
22+
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
23+
experimental-features = nix-command flakes
24+
system = ${{ matrix.arch }}
25+
- uses: cachix/cachix-action@v15
26+
with:
27+
name: khanelinix
28+
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
29+
- name: clear hostedtoolcache
30+
run: rm -rf /opt/hostedtoolcache
31+
- name: run flake check
32+
run: nix flake check --system ${{ matrix.arch }}

.github/workflows/label.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# This workflow will triage pull requests and apply a label based on the
2+
# paths that are modified in the pull request.
3+
#
4+
# To use this workflow, you will need to set up a .github/labeler.yml
5+
# file with configuration. For more information, see:
6+
# https://github.com/actions/labeler
7+
8+
name: Labeler
9+
on: [pull_request]
10+
jobs:
11+
label:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
contents: read
15+
pull-requests: write
16+
steps:
17+
- uses: actions/labeler@v5
18+
with:
19+
repo-token: "${{ secrets.GITHUB_TOKEN }}"

.github/workflows/update-flakes.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: "Update flakes"
2+
on:
3+
repository_dispatch:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: "0 0 * * *"
7+
jobs:
8+
createPullRequest:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v4
12+
- name: Install Nix
13+
uses: cachix/install-nix-action@v30
14+
with:
15+
extra_nix_config: |
16+
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
17+
- name: Update flake.lock
18+
uses: DeterminateSystems/update-flake-lock@v24
19+
with:
20+
pr-labels: |
21+
merge-queue

0 commit comments

Comments
 (0)