Modify gitlab ci for more generic files

Signed-off-by: Taylor Smock <taylor.smock@kaart.com>
pull/1/head
Taylor Smock 2019-10-17 09:32:24 -06:00
rodzic 7aa4c2bcfb
commit 64bc123e52
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 625F6A74A3E4311A
2 zmienionych plików z 24 dodań i 13 usunięć

Wyświetl plik

@ -142,18 +142,18 @@ build with java 13:
# dependencies:
# - build
# only:
# - master@gokaart/JOSM_MapWithAI
# - master
release:
stage: deploy
environment:
name: pages branch / dist directory
url: https://gitlab.com/gokaart/JOSM_MapWithAI/tree/pages/public/dist
url: ${CI_PAGES_URL}/${CI_PROJECT_NAME}
script:
- &clone_pages_branch |
echo "$SSH_PRIVATE_DEPLOY_KEY" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
git clone --depth 1 --branch pages git@gitlab.com:gokaart/JOSM_MapWithAI.git pages
git clone --depth 1 --branch pages ${CI_REPOSITORY_URL} pages
- |
version=`git describe --always --dirty`
longVersion=`git describe --always --long --dirty`
@ -166,20 +166,23 @@ release:
- &push_pages_branch |
cd pages/
git config user.name "Deploy with GitLab CI"
git config user.email "gokaart/JOSM_MapWithAI@gitlab.com"
git config user.email "${CI_PROJECT_NAMESPACE}/${CI_PROJECT_NAME}@${CI_SERVER_HOST}"
git stage .
git commit -a -m "$commitMessage"
git push origin pages
dependencies:
- build
only:
- tags@gokaart/JOSM_MapWithAI
refs:
- tags
variables:
- $SSH_PRIVATE_DEPLOY_KEY
publish master update site:
stage: deploy
environment:
name: pages branch / snapshot update site
url: https://gitlab.com/gokaart/JOSM_MapWithAI/tree/pages
url: ${CI_PAGES_URL}/${CI_PROJECT_NAME}/snapshot/master/update-site
script:
- *clone_pages_branch
- |
@ -194,17 +197,21 @@ publish master update site:
dependencies:
- build
only:
- master@gokaart/JOSM_MapWithAI
refs:
- master
variables:
- $SSH_PRIVATE_DEPLOY_KEY
publish to / GitLab.com packages:
stage: deploy
environment:
name: GitLab.com / JOSM-MapWithAI packages
url: https://gitlab.com/gokaart/JOSM_MapWithAI/-/packages
name: GitLab.com / ${CI_PROJECT_NAME} packages
url: ${CI_PROJECT_URL}/-/packages
script:
- ./gradlew publishAllPublicationsToGitlabRepository
- ./gradlew releaseToGitlab
dependencies:
- build
only:
- tags@gokaart/JOSM_MapWithAI
refs:
- tags

Wyświetl plik

@ -38,6 +38,11 @@ tasks.withType(JavaCompile).configureEach {
}
}
archivesBaseName = "mapwithai"
def gitlabGroup = "gokaart"
def gitlabRepositoryName = "JOSM_lane-connectivity"
def versions = [
awaitility: "4.0.1",
errorprone: "2.3.3",
@ -103,10 +108,9 @@ tasks.processResources {
from("$projectDir/src/resources")
}
archivesBaseName = "mapwithai"
josm {
i18n {
pathTransformer = getPathTransformer("gitlab.com/gokaart/JOSM_MapWithAI/blob")
pathTransformer = getPathTransformer("gitlab.com/${gitlabGroup}/${gitlabRepositoryName}/blob")
}
}
@ -159,7 +163,7 @@ task generateSnapshotUpdateSite(type: GeneratePluginList) {
outputFile = new File(project.buildDir, "snapshot-update-site")
versionSuffix = {a -> ""}
doFirst {
def pluginDownloadUrl = "https://gokaart.gitlab.io/JOSM_MapWithAI/snapshot/master/${archivesBaseName}.jar"
def pluginDownloadUrl = "https://${gitlabGroup}.gitlab.io/${gitlabRepositoryName}/snapshot/master/${archivesBaseName}.jar"
it.iconBase64Provider = {
def file = new File(sourceSets.main.resources.srcDirs[0], it)
if (file.exists()) {