Skip to content

Commit f18edff

Browse files
committed
refactor: Rename GITHUB_TOKEN to GITHUB_TOKEN_STARGAZERS
1 parent abaac59 commit f18edff

16 files changed

Lines changed: 21 additions & 22 deletions

.envrc-example

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use flake .
22
watch_file ./rust-toolchain.toml ./flake.nix
33

4-
export GITHUB_TOKEN="..."
4+
export GITHUB_TOKEN_STARGAZERS="..."
55
export GITHUB_WEBHOOK_SECRET="..."
66
export OPENAI_API_KEY="..."
77
export OPENAI_API_BASE_URL="https://api.openai.com"

.github/workflows/check-test-e2e.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646

4747
- name: Verify obelisk-local.toml
4848
env:
49-
GITHUB_TOKEN: ${{ secrets.E2E_GITHUB_TOKEN }}
49+
GITHUB_TOKEN_STARGAZERS: ${{ secrets.E2E_GITHUB_TOKEN }}
5050
TEST_GITHUB_LOGIN: ${{ secrets.TEST_GITHUB_LOGIN }}
5151
TURSO_TOKEN: ${{ secrets.E2E_TURSO_TOKEN }}
5252
TURSO_LOCATION: ${{ secrets.E2E_TURSO_LOCATION }}
@@ -55,7 +55,7 @@ jobs:
5555
5656
- name: Verify obelisk-oci.toml
5757
env:
58-
GITHUB_TOKEN: ${{ secrets.E2E_GITHUB_TOKEN }}
58+
GITHUB_TOKEN_STARGAZERS: ${{ secrets.E2E_GITHUB_TOKEN }}
5959
TEST_GITHUB_LOGIN: ${{ secrets.TEST_GITHUB_LOGIN }}
6060
TURSO_TOKEN: ${{ secrets.E2E_TURSO_TOKEN }}
6161
TURSO_LOCATION: ${{ secrets.E2E_TURSO_LOCATION }}
@@ -67,7 +67,7 @@ jobs:
6767

6868
- name: Verify obelisk-local-js-all.toml
6969
env:
70-
GITHUB_TOKEN: ${{ secrets.E2E_GITHUB_TOKEN }}
70+
GITHUB_TOKEN_STARGAZERS: ${{ secrets.E2E_GITHUB_TOKEN }}
7171
TEST_GITHUB_LOGIN: ${{ secrets.TEST_GITHUB_LOGIN }}
7272
TURSO_TOKEN: ${{ secrets.E2E_TURSO_TOKEN }}
7373
TURSO_LOCATION: ${{ secrets.E2E_TURSO_LOCATION }}
@@ -79,7 +79,7 @@ jobs:
7979

8080
- name: Verify obelisk-local-go-all.toml
8181
env:
82-
GITHUB_TOKEN: ${{ secrets.E2E_GITHUB_TOKEN }}
82+
GITHUB_TOKEN_STARGAZERS: ${{ secrets.E2E_GITHUB_TOKEN }}
8383
TEST_GITHUB_LOGIN: ${{ secrets.TEST_GITHUB_LOGIN }}
8484
TURSO_TOKEN: ${{ secrets.E2E_TURSO_TOKEN }}
8585
TURSO_LOCATION: ${{ secrets.E2E_TURSO_LOCATION }}

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ Here is the complete [workflow source](./workflow/stargazers/workflow-rs/src/lib
3333
### Setting up the external services
3434
The activities require folowing values to be present as environment variables:
3535
```sh
36-
export GITHUB_TOKEN="..."
36+
export GITHUB_TOKEN_STARGAZERS="..."
3737
export OPENAI_API_KEY="..."
3838
export TURSO_TOKEN="..."
3939
export GITHUB_WEBHOOK_SECRET="some-secret"

activity/github/impl/README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ The `account` interface fetches basic info like repositories, contributions etc.
66

77
## Prerequisites
88
[Classic GitHub token](https://github.com/settings/tokens/) with `read:org` permission is required.
9-
The token must be accesible as `GITHUB_TOKEN` environment variable.
9+
The token must be accesible as `GITHUB_TOKEN_STARGAZERS` environment variable.
1010
```sh
11-
export GITHUB_TOKEN="..."
11+
export GITHUB_TOKEN_STARGAZERS="..."
1212
```
1313

1414
## Running the activity
@@ -62,7 +62,6 @@ echo '
6262
{"query":"'$(echo $QUERY)'", "variables":{"repo":"obeli-sk/obelisk", "page":2}}
6363
' | curl -X POST \
6464
-H "User-Agent: test" \
65-
-H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/graphql \
65+
-H "Authorization: Bearer $GITHUB_TOKEN_STARGAZERS" https://api.github.com/graphql \
6666
-d @-
67-
6867
```

activity/github/impl/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use wstd::{
1313
};
1414
mod stargazers;
1515

16-
const ENV_GITHUB_TOKEN: &str = "GITHUB_TOKEN";
16+
const ENV_GITHUB_TOKEN: &str = "GITHUB_TOKEN_STARGAZERS";
1717

1818
mod generated {
1919
#![allow(clippy::empty_line_after_outer_attr)]

obelisk-local-go-activity.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ exec.lock_expiry.seconds = 5
1818
pattern = "https://api.github.com"
1919
methods = ["POST"]
2020
[activity_wasm.allowed_host.secrets]
21-
env_vars = ["GITHUB_TOKEN"]
21+
env_vars = ["GITHUB_TOKEN_STARGAZERS"]
2222
replace_in = ["headers"]
2323

2424
[[activity_wasm]]

obelisk-local-go-all.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ exec.lock_expiry.seconds = 5
1818
pattern = "https://api.github.com"
1919
methods = ["POST"]
2020
[activity_wasm.allowed_host.secrets]
21-
env_vars = ["GITHUB_TOKEN"]
21+
env_vars = ["GITHUB_TOKEN_STARGAZERS"]
2222
replace_in = ["headers"]
2323

2424
[[activity_wasm]]

obelisk-local-go-webhook.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ exec.lock_expiry.seconds = 5
1818
pattern = "https://api.github.com"
1919
methods = ["POST"]
2020
[activity_wasm.allowed_host.secrets]
21-
env_vars = ["GITHUB_TOKEN"]
21+
env_vars = ["GITHUB_TOKEN_STARGAZERS"]
2222
replace_in = ["headers"]
2323

2424
[[activity_wasm]]

obelisk-local-go-workflow.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ exec.lock_expiry.seconds = 5
1818
pattern = "https://api.github.com"
1919
methods = ["POST"]
2020
[activity_wasm.allowed_host.secrets]
21-
env_vars = ["GITHUB_TOKEN"]
21+
env_vars = ["GITHUB_TOKEN_STARGAZERS"]
2222
replace_in = ["headers"]
2323

2424
[[activity_wasm]]

obelisk-local-js-activity.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ exec.lock_expiry.seconds = 5
1818
pattern = "https://api.github.com"
1919
methods = ["POST"]
2020
[activity_wasm.allowed_host.secrets]
21-
env_vars = ["GITHUB_TOKEN"]
21+
env_vars = ["GITHUB_TOKEN_STARGAZERS"]
2222
replace_in = ["headers"]
2323

2424
[[activity_wasm]]

0 commit comments

Comments
 (0)