Skip to content

Commit

Permalink
😎 GitHub workflow fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
Sno committed Apr 14, 2024
1 parent b1ff83f commit e452f5f
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 36 deletions.
56 changes: 22 additions & 34 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,14 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4

- uses: actions/setup-go@v5
with:
go-version: '1.22.2'
check-latest: true

- name: Build
run: go build -o FTPDumper .

- name: Auto Increment Semver Action
uses: MCKanpolat/auto-semver-action@v1
id: versioning
Expand All @@ -25,45 +33,25 @@ jobs:
- name: Next Release Number
run: echo ${{ steps.versioning.outputs.version }}

- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.versioning.outputs.version }}
release_name: Release ${{ steps.versioning.outputs.version }}
body: |
Automatically created release by GitHub Actions
draft: false
prerelease: false

outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
version: ${{ steps.versioning.outputs.version }}


build:
name: Build and Upload
needs: release
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.22.2'
check-latest: true

- name: Build
run: go build -o FTPDumper

- name: Upload binary file
uses: softprops/action-gh-release@v2

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_REPOSITORY: MatrixTM/FTPDumper

with:
files: FTPDumper
files: FTPDumper
tag_name: beta-${{ steps.versioning.outputs.version }}
prerelease: true
name: Beta ${{ steps.versioning.outputs.version }}
repository: MatrixTM/FTPDumper
body: |
## Beta ${{ steps.versioning.outputs.version }} πŸ’­
${{ github.event.head_commit.message }}
[Download πŸ“₯](https://github.com/MatrixTM/FTPDumper/releases/download/beta-${{ steps.versioning.outputs.version }}/FTPDumper)
permissions:
Expand Down
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
FTPDumper
.idea
*.txt
*.exe
go.sum
*.exe
19 changes: 19 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ=
github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/hashicorp/errwrap v1.0.0 h1:hLrqtEDnRye3+sgx6z4qVLNuviH3MR5aQ0ykNJa/UYA=
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo=
github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM=
github.com/integrii/flaggy v1.5.2 h1:bWV20MQEngo4hWhno3i5Z9ISPxLPKj9NOGNwTWb/8IQ=
github.com/integrii/flaggy v1.5.2/go.mod h1:dO13u7SYuhk910nayCJ+s1DeAAGC1THCMj1uSFmwtQ8=
github.com/jlaffaye/ftp v0.2.0 h1:lXNvW7cBu7R/68bknOX3MrRIIqZ61zELs1P2RAiA3lg=
github.com/jlaffaye/ftp v0.2.0/go.mod h1:is2Ds5qkhceAPy2xD6RLI6hmp/qysSoymZ+Z2uTnspI=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/stretchr/testify v1.8.3 h1:RP3t2pwF7cMEbC1dqtB6poj3niw/9gnV4Cjg5oW5gtY=
github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=

0 comments on commit e452f5f

Please sign in to comment.