Skip to content

Conversation

@antonhinneck
Copy link

@antonhinneck antonhinneck commented Oct 26, 2022

Hi,
PkgTemplates.jl suits my needs to generate new projects with CI pipeline perfectly.
However, I need to be able to make further modifications to gitlab-ci.yml files (set variables during package creation).
While a custom template could be created, addressing this directly in PkgTemplates.jl would be

  • extremly straightforward and
  • one would not have to maintain an additional template, beyond what is already in this package.

With this PR, one could exemplarily set the http_proxy using GitLabCI like so:

tpl = Template(;
    dir="./",
    host="host.com",
    user="antonhinneck",
    plugins=[Git(), 
    GitLabCI(;coverage=true,
    file_prefix="variables:\n\thttp_proxy: 10.0.0.1\n")]
)

tpl("Pkg.jl")

All tests pass. Would this be sensible for the scope of this package?

Best,
Anton

Z004N5CH added 2 commits October 26, 2022 23:34
…view dict, added variable to template gitlab-ci.yml, included option in test
@codecov
Copy link

codecov bot commented Oct 26, 2022

Codecov Report

Merging #372 (0d1d29e) into master (0de5d85) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #372   +/-   ##
=======================================
  Coverage   95.03%   95.03%           
=======================================
  Files          20       20           
  Lines         644      644           
=======================================
  Hits          612      612           
  Misses         32       32           
Impacted Files Coverage Δ
src/plugins/ci.jl 97.46% <ø> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@gdalle
Copy link
Collaborator

gdalle commented Dec 18, 2023

I don't see a reason not to accept this. Can you add documentation and tests for this? The reference tests compare generated packages to a series of "fixtures", and they are only run for Julia 1.7.2. I suggest you modify the WackyOptions test suite accordingly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants