Skip to content

Commit

Permalink
edited monthly-run.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
charlottekostelic committed Apr 8, 2024
1 parent c20ab7f commit 5c0e940
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 72 deletions.
22 changes: 20 additions & 2 deletions .github/workflows/monthly-run.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ on:
# - chron: * 9 1 * *
jobs:
monthly-run:
name: Run monthly LCSH check
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- uses: actions/checkout@v4

Expand All @@ -33,11 +36,26 @@ jobs:
run: python monthly_lcsh_check.py


- name: Create issue
run: |
new_issue_url=$(gh issue create \
--title "$TITLE" \
--assignee "$ASSIGNEES" \
--body "$BODY")
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
TITLE: LCSH changed
ASSIGNEES: charlottekostelic
BODY: |
### Changed:
+ Updated list of terms in: data/acc_in.csv
+ See data/lcsh.log for lists of changed and deprecated terms
- name: Commit and push changed files
run:
git config --global user.name "Charlotte Kostelic"
git config --global user.email "[email protected]"
git add data/*
git commit -a -m "Monthly LCSH Check"
git push
git request-pull
git push
File renamed without changes.
69 changes: 0 additions & 69 deletions data/acc_out.csv

This file was deleted.

3 changes: 3 additions & 0 deletions data/lcsh.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
2024-04-08 12:41:27,016 - INFO - Checking id.loc.gov
2024-04-08 12:41:27,016 - INFO - No changes to ACC terms this month.
2024-04-08 12:41:27,016 - INFO - Updated list of current terms is in data/acc_out.csv
Empty file removed lcsh.log
Empty file.
2 changes: 1 addition & 1 deletion monthly_lcsh_check.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
today = datetime.datetime.strftime(datetime.datetime.now(), "%Y%m%d")
logger = LogSession(
logger_name="monthly_lcsh_check",
logfile="lcsh.log",
logfile="data/lcsh.log",
infile="data/acc_in.csv",
outfile="data/acc_out.csv",
)
Expand Down

0 comments on commit 5c0e940

Please sign in to comment.