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: Add to Journal | |
on: | |
workflow_dispatch: | |
inputs: | |
text: | |
description: Add a single item to Logseq journal | |
type: string | |
required: true | |
jobs: | |
add_to_journal: | |
name: Add item to journal | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: add line to file and commit | |
run: | | |
filename="journals/$(date +'%Y_%m_%d').md" | |
echo "- ${{ github.event.inputs.text }}" >> $filename | |
git config --local user.email "action@github.com" | |
git config --local user.name "GitHub Action" | |
git add $filename | |
git commit -m "Journal added by github action" | |
- name: Push changes | |
uses: ad-m/github-push-action@master |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment