Coding #988
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Coding | |
on: | |
schedule: | |
- cron: '0 23 * * 1-5' | |
jobs: | |
scrobbler: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@master | |
- name: init proccess | |
run: | | |
$Year = Get-Date -UFormat %Y | |
$Month = Get-Date -UFormat %m | |
if (!(Test-Path -Path wakatime\\$Year)) { | |
New-Item -Path wakatime\$Year -ItemType Directory | |
} | |
if (!(Test-Path -Path wakatime\\${Year}\\${Month})) { | |
New-Item -Path wakatime\$Year\$Month -ItemType Directory | |
} | |
pip install requests | |
python wakatime\script.py --path "wakatime/$Year/$Month" -t ${{ secrets.TOKEN_WAKATIME }} | |
git add "wakatime/$Year/$Month" | |
- name: Commit & Push changes | |
uses: actions-js/push@master | |
with: | |
github_token: ${{ secrets.TOKEN }} | |
author_name: EdgarVaguencia | |
author_email: ${{ secrets.EMAIL }} | |
message: 'Dandole atomos :metal:' |