Skip to content

Commit 3f21c49

Browse files
committed
Initial commit
0 parents  commit 3f21c49

221 files changed

Lines changed: 25125 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitattributes

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
* text=auto eol=lf
2+
3+
*.js text
4+
*.ts text
5+
*.toml text
6+
*.json text
7+
*.jsonc text
8+
*.yaml text
9+
*.yml text
10+
*.md text
11+
*.css text
12+
*.html text
13+
*.csv text
14+
15+
# Shell & Windows specific scripts
16+
*.sh text eol=lf
17+
*.bat text eol=crlf
18+
*.cmd text eol=crlf
19+
20+
# Binary files
21+
*.png binary
22+
*.jpg binary
23+
*.jpeg binary
24+
*.gif binary
25+
*.ico binary
26+
*.mov binary
27+
*.mp4 binary
28+
*.woff binary
29+
*.woff2 binary
30+
*.ttf binary
31+
*.eot binary
32+
33+
# Hide generated files from diffs and language statistics
34+
bun.lock linguist-generated

.github/renovate.json

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
3+
"extends": [
4+
"config:recommended",
5+
":preserveSemverRanges",
6+
"npm:unpublishSafe"
7+
],
8+
"timezone": "Etc/UTC",
9+
"schedule": [
10+
"* 0-4 * * 1-3"
11+
],
12+
"labels": [
13+
"dependencies"
14+
],
15+
"commitMessagePrefix": "chore: ",
16+
"commitMessageAction": "bump up",
17+
"commitMessageTopic": "{{depName}} version",
18+
"ignoreDeps": [],
19+
"packageRules": [
20+
{
21+
"groupName": "all non-major dependencies",
22+
"groupSlug": "all-minor-patch",
23+
"matchPackageNames": [
24+
"*"
25+
],
26+
"matchUpdateTypes": [
27+
"minor",
28+
"patch"
29+
]
30+
},
31+
{
32+
"groupName": "all devDependencies",
33+
"groupSlug": "all-dev-dependencies",
34+
"matchDepTypes": [
35+
"devDependencies"
36+
],
37+
"rangeStrategy": "bump"
38+
}
39+
]
40+
}

.github/workflows/ci.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: CI
2+
on:
3+
push:
4+
paths:
5+
- packages/**
6+
- tests/**
7+
- bun.lock
8+
branches:
9+
- main
10+
pull_request:
11+
paths:
12+
- packages/**
13+
- tests/**
14+
- bun.lock
15+
branches:
16+
- main
17+
18+
permissions:
19+
contents: write
20+
id-token: write
21+
22+
env:
23+
ACTION_CACHE_PATH: |
24+
~/.bun/install/cache
25+
node_modules/
26+
27+
concurrency:
28+
group: ${{ github.workflow }}-${{ github.ref }}
29+
cancel-in-progress: true
30+
jobs:
31+
test:
32+
name: Run Tests
33+
runs-on: ubuntu-latest
34+
steps:
35+
- uses: actions/checkout@v6
36+
- uses: actions/setup-node@v6
37+
with:
38+
node-version: 24
39+
- uses: oven-sh/setup-bun@v2
40+
- uses: actions/cache@v5
41+
with:
42+
path: ${{ env.ACTION_CACHE_PATH }}
43+
- run: bun install
44+
- run: bun run build
45+
- run: bun run test

.github/workflows/docs.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Deploy Docs to GitHub Pages
2+
on:
3+
push:
4+
paths:
5+
- docs/**
6+
branches:
7+
- main
8+
workflow_dispatch:
9+
10+
permissions:
11+
contents: read
12+
pages: write
13+
id-token: write
14+
15+
env:
16+
ACTION_CACHE_PATH: |
17+
~/.bun/install/cache
18+
node_modules/
19+
20+
jobs:
21+
build:
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v6
25+
- uses: oven-sh/setup-bun@v2
26+
- uses: actions/cache@v5
27+
with:
28+
path: ${{ env.ACTION_CACHE_PATH }}
29+
- uses: withastro/action@v6
30+
with:
31+
path: ./docs/
32+
deploy:
33+
needs: build
34+
runs-on: ubuntu-latest
35+
environment:
36+
name: github-pages
37+
url: ${{ steps.deployment.outputs.page_url }}
38+
steps:
39+
- uses: actions/deploy-pages@v5
40+
id: deployment

.github/workflows/release.yml

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: Release
2+
on:
3+
workflow_dispatch:
4+
inputs:
5+
package:
6+
type: choice
7+
required: true
8+
description: Package
9+
options:
10+
- sysopkit
11+
- "@sysopkit/linux"
12+
- "@sysopkit/openwrt"
13+
- "@sysopkit/openwrt"
14+
- "@sysopkit/cli"
15+
increment:
16+
type: choice
17+
required: true
18+
description: Increment version
19+
options:
20+
- patch
21+
- minor
22+
- major
23+
24+
permissions:
25+
contents: write
26+
id-token: write
27+
28+
env:
29+
ACTION_CACHE_PATH: |
30+
~/.bun/install/cache
31+
node_modules/
32+
33+
jobs:
34+
release:
35+
name: Increment version
36+
runs-on: ubuntu-latest
37+
steps:
38+
- uses: actions/checkout@v6
39+
- uses: actions/setup-node@v6
40+
with:
41+
node-version: 24
42+
- uses: oven-sh/setup-bun@v2
43+
- uses: actions/cache@v5
44+
with:
45+
path: ${{ env.ACTION_CACHE_PATH }}
46+
- run: bun install
47+
- run: bun run build
48+
- run: bun run test
49+
- name: Increment versions and push changes
50+
run: |
51+
cd ./packages/${{ github.event.inputs.package }}
52+
bun pm version "${{ github.event.inputs.increment }}" --no-git-tag-version
53+
NEW_VERSION="$(jq -r .version package.json)"
54+
cd -
55+
bun install
56+
git config --global user.name "GitHub Action"
57+
git config --global user.email "username@users.noreply.github.com"
58+
git commit -a -m "publish: ${{ github.event.inputs.package }} ${NEW_VERSION}"
59+
git push
60+
- name: Publish to NPM
61+
run: |
62+
npm config set provenance true
63+
echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> ~/.npmrc
64+
./scripts/publish.sh ./packages/sysopkit --provenance
65+
./scripts/publish.sh ./packages/@sysopkit/linux --provenance
66+
./scripts/publish.sh ./packages/@sysopkit/openwrt --provenance
67+
./scripts/publish.sh ./packages/@sysopkit/cli --provenance

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
/packages/**/dist
2+
3+
node_modules
4+
*.tsbuildinfo

.oxfmtrc.json

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
"$schema": "./node_modules/oxfmt/configuration_schema.json",
3+
"tabWidth": 2,
4+
"semi": true,
5+
"printWidth": 100,
6+
"singleQuote": true,
7+
"endOfLine": "lf",
8+
"trailingComma": "all",
9+
"proseWrap": "never",
10+
"quoteProps": "consistent",
11+
"sortImports": {
12+
"newlinesBetween": false,
13+
"groups": [
14+
"type-import",
15+
"value-builtin",
16+
"value-external",
17+
"type-internal",
18+
"value-internal",
19+
{
20+
"newlinesBetween": true
21+
},
22+
["subpath"],
23+
["type-parent", "type-sibling", "type-index"],
24+
["value-parent", "value-sibling", "value-index"],
25+
["style", "side_effect_style"],
26+
"unknown"
27+
]
28+
},
29+
"sortPackageJson": true,
30+
"ignorePatterns": ["bun.lock", "packages/@sysopkit/*/dist/**", "packages/*/dist/**"]
31+
}

.oxlintrc.json

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
{
2+
"$schema": "./node_modules/oxlint/configuration_schema.json",
3+
"plugins": [
4+
"unicorn",
5+
"typescript",
6+
"oxc"
7+
],
8+
"options": {
9+
"typeAware": true,
10+
"typeCheck": true
11+
},
12+
"categories": {
13+
"correctness": "error"
14+
},
15+
"rules": {
16+
"eqeqeq": [
17+
"error",
18+
"always",
19+
{
20+
"null": "ignore"
21+
}
22+
],
23+
"no-empty": [
24+
"warn",
25+
{
26+
"allowEmptyCatch": true
27+
}
28+
],
29+
"typescript/consistent-type-imports": [
30+
"warn",
31+
{
32+
"prefer": "type-imports",
33+
"fixStyle": "separate-type-imports"
34+
}
35+
],
36+
"typescript/prefer-regexp-exec": "error",
37+
"typescript/no-this-alias": "allow"
38+
},
39+
"env": {
40+
"builtin": true,
41+
"es2024": true,
42+
"node": true
43+
},
44+
"globals": {},
45+
"ignorePatterns": [
46+
"packages/@sysopkit/*/dist/**",
47+
"packages/*/dist/**",
48+
"docs/.astro/**",
49+
"docs/dist/**"
50+
]
51+
}

0 commit comments

Comments
 (0)