Skip to content

Commit 8a97c87

Browse files
committed
chore: initial commit
0 parents  commit 8a97c87

30 files changed

Lines changed: 6788 additions & 0 deletions

.editorconfig

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
indent_style = space
6+
indent_size = 2
7+
end_of_line = lf
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true

.github/workflows/ci.yml

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
pull_request:
9+
branches:
10+
- main
11+
12+
jobs:
13+
lint:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v5
17+
18+
- name: Install pnpm
19+
uses: pnpm/action-setup@v4
20+
21+
- name: Set node
22+
uses: actions/setup-node@v5
23+
with:
24+
node-version: lts/*
25+
cache: pnpm
26+
27+
- name: Setup
28+
run: npm i -g @antfu/ni
29+
30+
- name: Install
31+
run: nci
32+
33+
- name: Lint
34+
run: nr lint
35+
36+
typecheck:
37+
runs-on: ubuntu-latest
38+
steps:
39+
- uses: actions/checkout@v5
40+
41+
- name: Install pnpm
42+
uses: pnpm/action-setup@v4
43+
44+
- name: Set node
45+
uses: actions/setup-node@v5
46+
with:
47+
node-version: lts/*
48+
cache: pnpm
49+
50+
- name: Setup
51+
run: npm i -g @antfu/ni
52+
53+
- name: Install
54+
run: nci
55+
56+
- name: Typecheck
57+
run: nr typecheck
58+
59+
test:
60+
runs-on: ${{ matrix.os }}
61+
62+
strategy:
63+
matrix:
64+
node: [lts/*]
65+
os: [ubuntu-latest, windows-latest, macos-latest]
66+
fail-fast: false
67+
68+
steps:
69+
- uses: actions/checkout@v5
70+
71+
- name: Install pnpm
72+
uses: pnpm/action-setup@v4
73+
74+
- name: Set node ${{ matrix.node }}
75+
uses: actions/setup-node@v5
76+
with:
77+
node-version: ${{ matrix.node }}
78+
cache: pnpm
79+
80+
- name: Setup
81+
run: npm i -g @antfu/ni
82+
83+
- name: Install
84+
run: nci
85+
86+
- name: Build
87+
run: nr build
88+
89+
- name: Test
90+
run: nr test

.github/workflows/release.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
jobs:
9+
release:
10+
permissions:
11+
id-token: write
12+
contents: write
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v5
16+
with:
17+
fetch-depth: 0
18+
19+
- name: Install pnpm
20+
uses: pnpm/action-setup@v4
21+
22+
- name: Set node
23+
uses: actions/setup-node@v5
24+
with:
25+
node-version: lts/*
26+
cache: pnpm
27+
registry-url: 'https://registry.npmjs.org'
28+
29+
- run: npx changelogithub
30+
continue-on-error: true
31+
env:
32+
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

.gitignore

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
pnpm-debug.log*
8+
lerna-debug.log*
9+
10+
node_modules
11+
es
12+
dist
13+
dist-ssr
14+
dev-dist
15+
*.local
16+
17+
# Editor directories and files
18+
.idea
19+
.turbo
20+
.DS_Store
21+
*.suo
22+
*.ntvs*
23+
*.njsproj
24+
*.sln
25+
*.sw?

.npmrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
registry=https://registry.npmjs.org/
2+
ignore-workspace-root-check=true
3+
shell-emulator=true

.vscode/settings.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"cSpell.words": [
3+
"clashx"
4+
]
5+
}

LICENSE.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025 Jing Haihan
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Raycast Clash
2+
3+
Monitor your Clash with Raycast.
4+
5+
```sh
6+
npx rayext install jinghaihan/raycast-clash
7+
```
8+
9+
<div align="center">
10+
<img src="./assets/screenshot.png" alt="screenshot">
11+
</div>
12+
13+
## Commands
14+
15+
<!-- commands -->
16+
17+
| Title | Description |
18+
| --------------------- | -------------------------- |
19+
| `Mode` | Switch proxy mode |
20+
| `Proxies` | Select proxy |
21+
| `Toggle System Proxy` | Toggle system proxy on/off |
22+
23+
<!-- commands -->
24+
25+
## Configuration
26+
27+
<!-- configs -->
28+
29+
| Key | Description | Required | Default |
30+
| ------------------ | ---------------------------- | -------- | ------------------------------------- |
31+
| `app` | The app to toggle proxy | `No` | ClashX Pro |
32+
| `url` | The URL of the Clash API | `No` | http://127.0.0.1:9090 |
33+
| `secret` | The secret of the Clash API | `No` | |
34+
| `benchMarkTimeout` | The timeout of the benchmark | `No` | 5000 |
35+
| `benchMarkUrl` | The URL of the benchmark | `No` | http://cp.cloudflare.com/generate_204 |
36+
37+
<!-- configs -->
38+
39+
## License
40+
41+
[MIT](./LICENSE) License © [jinghaihan](https://github.com/jinghaihan)

assets/icon.png

22.6 KB
Loading

assets/screenshot.png

196 KB
Loading

0 commit comments

Comments
 (0)