-
Notifications
You must be signed in to change notification settings - Fork 6
37 lines (34 loc) · 1.13 KB
/
dump-aaguids.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
on:
schedule:
- cron: '0 8 */1 * *'
workflow_dispatch:
permissions:
contents: write
name: Dump AAGuids
jobs:
build:
runs-on: ubuntu-latest
name: Dump latest AAGUIDs
steps:
- uses: actions/checkout@v3
- name: Dump AAGUIDs
run: |
$uri = 'https://github.com/passkeydeveloper/passkey-authenticator-aaguids/raw/main/combined_aaguid.json'
$targetPath = 'Watchlists/aaguids.json'
$data = Invoke-RestMethod -Uri $uri
$aaGuidInfo = @{}
$data.psobject.properties.name | ForEach-Object { $aaGuidInfo[$PSItem] = $data.$PSItem }
$aaGuidInfo.GetEnumerator() | ForEach-Object {
[PSCustomObject]@{
AAGuid = $_.Key
Name = $_.Value.Name
}
} | ConvertTo-Json | Set-Content $targetPath -Encoding utf8 -Force
shell: pwsh
- name: Commit and push changes
run: |
git config --global user.name 'AAGuid dump'
git config --global user.email '[email protected]'
git add .
git commit -am "AAGuid dump"
git push