Skip to content

Commit 8a4aa8f

Browse files
committed
#58 fix keys.ts
1 parent 0aec5d4 commit 8a4aa8f

File tree

2 files changed

+4
-20
lines changed

2 files changed

+4
-20
lines changed

.github/workflows/CI-mutation-tests.yml

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -24,28 +24,12 @@ jobs:
2424
run: npm install
2525

2626
- name: Inject Secrets
27-
shell: python
2827
env:
2928
SCOPES: ${{ secrets.scopes }}
3029
CLIENT_ID: ${{ secrets.client_id }}
3130
AUTHORITY: ${{ secrets.authority }}
32-
BASE_PATH: "src/environments/"
3331
run: |
34-
import os
35-
base_path = os.environ.get('BASE_PATH', 'src/environments/')
36-
with open(base_path + "keys.ts", "w") as fileWithKeys:
37-
scopes = str(os.environ['SCOPES'])
38-
export_scopes = f'export const SCOPES = ["{scopes}"];'
39-
print(export_scopes)
40-
client_id = os.environ['CLIENT_ID']
41-
export_client_id = f'export const CLIENT_ID = "{client_id}";\n'
42-
print(export_client_id)
43-
authority = os.environ['AUTHORITY']
44-
export_authority = f'export const AUTHORITY = "{authority}";\n'
45-
print(export_authority)
46-
fileWithKeys.write(export_scopes)
47-
fileWithKeys.write(export_authority)
48-
fileWithKeys.write(export_client_id)
32+
> src/environments/keys.ts && echo 'export const AUTHORITY = "'$AUTHORITY'";' >> src/environments/keys.ts && echo 'export const CLIENT_ID = "'$CLIENT_ID'";' >> src/environments/keys.ts && echo 'export const SCOPES = ["'$SCOPES'"];' >> src/environments/keys.ts
4933

5034
- name: Run the test
5135
run: npm run ci-test --if-present

src/environments/keys.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
export const AUTHORITY = 'XXX';
2-
export const CLIENT_ID = 'XXX';
3-
export const SCOPES = ['XXX'];
1+
export const AUTHORITY = 'ABC';
2+
export const CLIENT_ID = 'XYZ';
3+
export const SCOPES = ['ABC'];

0 commit comments

Comments
 (0)