This commit is contained in:
49
.gitea/workflows/build.yml
Normal file
49
.gitea/workflows/build.yml
Normal file
@@ -0,0 +1,49 @@
|
||||
name: Build Urlshort
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master ]
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout código
|
||||
run: |
|
||||
git clone https://fedesrv.ddns.net/git/${{ github.repository }}.git .
|
||||
git checkout ${{ github.sha }}
|
||||
|
||||
- name: Setup Go 1.21.x
|
||||
uses: actions/setup-go@v5
|
||||
with:
|
||||
# Semantic version range syntax or exact version of Go
|
||||
go-version: '1.21.7'
|
||||
|
||||
- name: Install dependencias go
|
||||
run: go get .
|
||||
|
||||
- name: build binary go
|
||||
run: go build -v .
|
||||
|
||||
- name: Setup Bun
|
||||
uses: oven-sh/setup-bun@v1
|
||||
with:
|
||||
bun-version: latest
|
||||
|
||||
- name: build proyect
|
||||
run: |
|
||||
cd front
|
||||
bun run build
|
||||
|
||||
- name: copy artifacts
|
||||
run: |
|
||||
mkdir -p upload
|
||||
cp ./url-short upload/
|
||||
cp -r front/dist upload/
|
||||
echo "Upload complete"
|
||||
|
||||
- name: Upload dist
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
path: upload
|
||||
Reference in New Issue
Block a user