@@ -206,7 +206,7 @@ def __init__(self, parser: argparse.ArgumentParser):
206206 self .git_remote_url = ""
207207 self .git_hoster : GitHoster = GitHoster .Empty
208208 self .template_base_url : str = "https://raw.githubusercontent.com"
209- self .template_branch : str = "feature/jinja "
209+ self .template_branch : str = "main "
210210 self .template_repo : str = "softwarepub/ci-templates"
211211 self .template_folder : str = "init-templates"
212212 self .ci_parameters : dict = {
@@ -323,7 +323,7 @@ def __call__(self, args: argparse.Namespace) -> None:
323323 # Nice message on Ctrl+C
324324 except KeyboardInterrupt :
325325 sc .echo ("" )
326- sc .echo ("HERMES init was aborted. No changes were made. " , sc .Formats .WARNING )
326+ sc .echo ("HERMES init was aborted." , sc .Formats .WARNING )
327327 self .clean_up_files (True )
328328 sys .exit ()
329329
@@ -333,7 +333,7 @@ def __call__(self, args: argparse.Namespace) -> None:
333333 formatting = sc .Formats .FAIL + sc .Formats .BOLD )
334334 sc .debug_info (traceback .format_exc ())
335335 self .clean_up_files (True )
336- sc .echo ("No changes were made . You will have to run 'hermes init' again." )
336+ sc .echo ("The initialization was not finalized . You will have to run 'hermes init' again." )
337337 sys .exit (2 )
338338
339339 def check_hermes_version (self ) -> None :
@@ -496,7 +496,7 @@ def create_ci_template(self) -> None:
496496 """Downloads and configures the ci workflow files using templates from the chosen template branch."""
497497 match self .git_hoster :
498498 case GitHoster .GitHub :
499- template_url = self .get_template_url ("TEMPLATE_hermes_github_to_zenodo .yml" )
499+ template_url = self .get_template_url ("hermes_github .yml" )
500500 ci_file_folder = Path (".github/workflows" )
501501 ci_file_name = "hermes_github.yml"
502502 ci_file_path = ci_file_folder / ci_file_name
@@ -511,7 +511,7 @@ def create_ci_template(self) -> None:
511511 self .configure_ci_template (ci_file_path )
512512 sc .echo (f"GitHub CI: File was created at { ci_file_path } " , formatting = sc .Formats .OKGREEN )
513513 case GitHoster .GitLab :
514- gitlab_ci_template_url = self .get_template_url ("TEMPLATE_hermes_gitlab_to_zenodo .yml" )
514+ gitlab_ci_template_url = self .get_template_url ("hermes_gitlab .yml" )
515515 hermes_ci_template_url = self .get_template_url ("hermes-ci.yml" )
516516 gitlab_ci_path = Path (".gitlab-ci.yml" )
517517 gitlab_folder_path = Path ("gitlab" )
@@ -534,6 +534,7 @@ def create_ci_template(self) -> None:
534534 sc .echo (f"GitLab CI: { gitlab_ci_path } was created." , formatting = sc .Formats .OKGREEN )
535535 self .configure_ci_template (gitlab_ci_path )
536536 # Creating hermes-ci
537+ sc .debug_info (f"Downloading gitlab hermes-ci template from { hermes_ci_template_url } " )
537538 download_file_from_url (hermes_ci_template_url , hermes_ci_path )
538539 self .configure_ci_template (hermes_ci_path )
539540
@@ -557,7 +558,7 @@ def configure_ci_template(self, ci_file_path) -> None:
557558 template = jinja_env .get_template (str (ci_file_path ))
558559 missing = [p for p in used_params if p not in self .ci_parameters ]
559560 if missing :
560- sc .echo ("CI Template has missing parameters: {missing}" , formatting = sc .Formats .WARNING )
561+ sc .echo (f "CI Template has missing parameters: { missing } " , formatting = sc .Formats .WARNING )
561562 rendered = template .render (self .ci_parameters )
562563 with open (ci_file_path , 'w' ) as file :
563564 file .write (rendered )
0 commit comments