Skip to content
Snippets Groups Projects
Commit c4ea7aea authored by René Schöne's avatar René Schöne
Browse files

Some ideas.

- replace project_gitlab_id with $System.env.CI_PROJECT_ID, update readme
- cache gradle distro
- fix diagram creation
- add git remote after init
parent 86c12352
No related branches found
No related tags found
1 merge request!1Resolve "Initial Review"
......@@ -6,5 +6,5 @@ Requirements:
Usage:
1. Create a [new project](https://git-st.inf.tu-dresden.de/projects/new). Note the URL to clone the project and its project ID.
2. Run `cookiecutter https://git-st.inf.tu-dresden.de/jastadd/project-templates/relast` and put in your information, especially the URL from step 1 as `project_url` and the project ID from step 1 as `project_gitlab_id`.
1. Create a [new project](https://git-st.inf.tu-dresden.de/projects/new). Note the URL to clone the project.
2. Run `cookiecutter https://git-st.inf.tu-dresden.de/jastadd/project-templates/relast` and put in your information, especially the URL from step 1 as `project_url`.
......@@ -3,7 +3,6 @@
"project_name": "My New Relational RAG Project",
"project_short_name": "NewRelAST",
"project_slug": "{{cookiecutter.project_name|replace(' ','_')|lower}}",
"project_gitlab_id": "001",
"package": "jastadd",
"project_url": "git@git-st.inf.tu-dresden.de:{{cookiecutter.package}}/{{cookiecutter.repo_name}}.git",
"repo_url": "https://git-st.inf.tu-dresden.de/{{cookiecutter.package}}/{{cookiecutter.repo_name}}",
......
import sys
import subprocess
PROJECT_URL = '{{cookiecutter.project_url}}'
def main():
subprocess.call(['git', 'init'])
subprocess.call(['git', 'remote', 'add', 'origin', PROJECT_URL])
if __name__ == '__main__':
main()
variables:
GIT_SUBMODULE_STRATEGY: recursive
before_script:
- export GRADLE_USER_HOME=`pwd`/.gradle
cache:
paths:
- .gradle/wrapper
- .gradle/caches
stages:
- build
- test
......@@ -89,7 +97,8 @@ pages:
before_script:
- pip install -r pages/requirements.txt
script:
- cp -r src/gen/resources/{{cookiecutter.project_short_name}}Grammar.png pages/docs/diagrams
- mkdir pages/docs/diagrams
- cp src/gen/resources/{{cookiecutter.project_short_name}}Grammar.png pages/docs/diagrams/
- cd pages && mkdocs build
artifacts:
paths:
......
......@@ -169,7 +169,7 @@ jastadd {
}
// publish gitlab project {{cookiecutter.project_gitlab_id}}
// publish gitlab project
publishing {
publications {
maven(MavenPublication) {
......@@ -182,7 +182,7 @@ publishing {
}
repositories {
maven {
url "https://git-st.inf.tu-dresden.de/api/v4/projects/{{cookiecutter.project_gitlab_id}}/packages/maven"
url "https://git-st.inf.tu-dresden.de/api/v4/projects/$System.env.CI_PROJECT_ID/packages/maven"
// Uncomment the following lines to publish manually (and comment out the other credentials section)
// credentials(HttpHeaderCredentials) {
// name = "Private-Token"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment