diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..1e263d1 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,60 @@ +# This is a basic workflow to help you get started with Actions + +name: CI + +# Controls when the action will run. +on: + # Triggers the workflow on push or pull request events but only for the master branch + push: + branches: [ master ] + tags: + - '*' + pull_request: + branches: [ master ] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "build" + build: + # The type of runner that the job will run on + runs-on: windows-latest + if: contains(github.ref, 'tags') + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v2 + + # Setup autoit environment + - uses: liudonghua123/action-setup-autoit@main + + # Runs build + - name: Run build + shell: cmd + run: | + "C:\Program Files (x86)\AutoIt3\AutoIt3.exe" "C:\Program Files (x86)\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.au3" /in MyChrome.au3 /NoStatus + + # Check the output + - name: Check the output + shell: bash + run: | + ls -l + + # Package the binaries + - name: Package the binaries + shell: bash + run: | + 7z a -tzip MyChrome.zip MyChrome.exe MyChrome_x64.exe + + # Deploy to the github release + - uses: xresloader/upload-to-github-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + file: MyChrome.zip + tags: true + draft: false + overwrite: true