Skip to content

Commit 3a34941

Browse files
authored
Update deploy.yml
1 parent b9d437e commit 3a34941

File tree

1 file changed

+6
-24
lines changed

1 file changed

+6
-24
lines changed

.github/workflows/deploy.yml

Lines changed: 6 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
name: Publicar a Maven Central
2-
32
on:
43
workflow_dispatch:
54
inputs:
65
release_notes:
76
description: 'Notas de la versión'
87
required: false
98
default: 'Nueva versión de la biblioteca FiscalAPI'
10-
119
jobs:
1210
publish:
1311
runs-on: ubuntu-latest
@@ -16,21 +14,21 @@ jobs:
1614
uses: actions/checkout@v3
1715
with:
1816
ref: ${{ github.ref_name }}
19-
17+
2018
- name: Configurar Java
2119
uses: actions/setup-java@v3
2220
with:
2321
java-version: '8'
2422
distribution: 'temurin'
2523
cache: maven
26-
24+
2725
- name: Extraer versión del POM
2826
id: get_version
2927
run: |
3028
VERSION=$(grep -m 1 "<version>" pom.xml | sed 's/<version>//g' | sed 's/<\/version>//g' | xargs)
3129
echo "Versión extraída del POM: $VERSION"
3230
echo "version=$VERSION" >> $GITHUB_OUTPUT
33-
31+
3432
- name: Configurar GPG
3533
run: |
3634
# Crear directorio para las claves GPG
@@ -43,7 +41,7 @@ jobs:
4341
4442
# Verificar que las claves se hayan importado correctamente
4543
gpg --list-secret-keys --keyid-format LONG
46-
44+
4745
- name: Verificar settings.xml
4846
run: |
4947
if [ -f "settings.xml" ]; then
@@ -52,31 +50,15 @@ jobs:
5250
echo "Error: No se encontró el archivo settings.xml"
5351
exit 1
5452
fi
55-
53+
5654
- name: Desplegar a Maven Central
5755
env:
5856
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
5957
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
6058
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
6159
run: |
6260
mvn clean deploy -P release --settings settings.xml -DskipTests=true
63-
64-
- name: Crear GitHub Release
65-
if: success()
66-
uses: softprops/action-gh-release@v1
67-
with:
68-
tag_name: v${{ steps.get_version.outputs.version }}
69-
name: FiscalAPI ${{ steps.get_version.outputs.version }}
70-
body: ${{ github.event.inputs.release_notes }}
71-
draft: false
72-
prerelease: false
73-
files: |
74-
target/fiscalapi-${{ steps.get_version.outputs.version }}.jar
75-
target/fiscalapi-${{ steps.get_version.outputs.version }}-javadoc.jar
76-
target/fiscalapi-${{ steps.get_version.outputs.version }}-sources.jar
77-
env:
78-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
79-
61+
8062
- name: Notificar resultado
8163
if: always()
8264
run: |

0 commit comments

Comments
 (0)