Merge pull request #4 from R3DRUN3/dependabot/go_modules/github.com/c… #39
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: goaction | |
on: | |
#schedule: | |
#- cron: '0 0 */15 * *' # uncomment this schedule to run at midnight every 15 day of every months | |
push: | |
paths: | |
- '**' | |
- '!README.md' | |
- '!**/.gitignore' | |
- '!**/Dockerfile' | |
- '!**/LICENSE' | |
jobs: | |
lint-and-goaction: | |
runs-on: ubuntu-latest | |
permissions: write-all | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v2 | |
- name: Set up Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: '1.20' | |
- name: Lint Go Code | |
run: go vet ./... | |
- name: Check out repository | |
uses: actions/checkout@v3 | |
- name: Set up Go | |
uses: actions/setup-go@v3 | |
with: | |
go-version: '1.20' | |
- name: Set up environment variables | |
run: | | |
echo "TOKEN=${{ secrets.TOKEN }}" >> $GITHUB_ENV | |
echo "REPO_FOLDER_1=en" >> $GITHUB_ENV | |
echo "REPO_FOLDER_2=it" >> $GITHUB_ENV | |
echo "REPO_URL=https://github.com/r3drun3/content-sync-tester" >> $GITHUB_ENV | |
echo "OPEN_ISSUE=true" >> $GITHUB_ENV | |
# uncomment the following to execute guthub-content-sync inside the CI pipeline | |
# - name: Execute Go Script | |
# run: go run main.go | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.TOKEN }} | |
# REPO_FOLDER_1: ${{ env.REPO_FOLDER_1 }} | |
# REPO_FOLDER_2: ${{ env.REPO_FOLDER_2 }} | |
# REPO_URL: ${{ env.REPO_URL }} | |
# OPEN_ISSUE: ${{ env.OPEN_ISSUE }} |