@intentius/chant-lexicon-gitlab 0.1.12 → 0.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/dist/integrity.json +3 -2
- package/dist/manifest.json +1 -1
- package/dist/skills/chant-gitlab-migrate.md +117 -0
- package/package.json +11 -4
- package/src/import/generator.ts +20 -2
- package/src/migrate/from-github/actions/index.ts +27 -0
- package/src/migrate/from-github/actions/registry.ts +112 -0
- package/src/migrate/from-github/actions/tier-1.test.ts +128 -0
- package/src/migrate/from-github/actions/tier-1.ts +325 -0
- package/src/migrate/from-github/actions/tier-2-3.test.ts +144 -0
- package/src/migrate/from-github/actions/tier-2.ts +296 -0
- package/src/migrate/from-github/actions/tier-3.ts +124 -0
- package/src/migrate/from-github/composites/patterns.ts +167 -0
- package/src/migrate/from-github/composites/rewriter.test.ts +98 -0
- package/src/migrate/from-github/composites/rewriter.ts +29 -0
- package/src/migrate/from-github/diagnostics.ts +45 -0
- package/src/migrate/from-github/emit-ts.test.ts +49 -0
- package/src/migrate/from-github/emit-yaml.ts +128 -0
- package/src/migrate/from-github/expressions.test.ts +124 -0
- package/src/migrate/from-github/expressions.ts +302 -0
- package/src/migrate/from-github/fixtures/README.md +27 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-checkout/expected-report.json +15 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-checkout/expected.gitlab-ci.yml +13 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-checkout/input.yml +7 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-setup-node/expected-report.json +20 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-setup-node/expected.gitlab-ci.yml +20 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-setup-node/input.yml +12 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-setup-python/expected-report.json +20 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-setup-python/expected.gitlab-ci.yml +17 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/actions-setup-python/input.yml +12 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/docker-build-push/expected-report.json +24 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/docker-build-push/expected.gitlab-ci.yml +20 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/docker-build-push/input.yml +16 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/upload-download-artifact/expected-report.json +24 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/upload-download-artifact/expected.gitlab-ci.yml +27 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/upload-download-artifact/input.yml +20 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/codecov-action/expected-report.json +24 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/codecov-action/expected.gitlab-ci.yml +15 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/codecov-action/input.yml +13 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/setup-bun/expected-report.json +20 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/setup-bun/expected.gitlab-ci.yml +17 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/setup-bun/input.yml +11 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-3/paths-filter/expected-report.json +21 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-3/paths-filter/expected.gitlab-ci.yml +15 -0
- package/src/migrate/from-github/fixtures/marketplace-actions/tier-3/paths-filter/input.yml +11 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/01-triggers/expected-report.json +20 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/01-triggers/expected.gitlab-ci.yml +16 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/01-triggers/input.yml +12 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/02-stages-needs/expected-report.json +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/02-stages-needs/expected.gitlab-ci.yml +31 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/02-stages-needs/input.yml +16 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/03-matrix/expected-report.json +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/03-matrix/expected.gitlab-ci.yml +20 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/03-matrix/input.yml +10 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/04-env-secrets/expected-report.json +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/04-env-secrets/expected.gitlab-ci.yml +18 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/04-env-secrets/input.yml +11 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/05-conditional/expected-report.json +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/05-conditional/expected.gitlab-ci.yml +24 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/05-conditional/input.yml +12 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/06-services/expected-report.json +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/06-services/expected.gitlab-ci.yml +18 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/06-services/input.yml +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/07-job-control/expected-report.json +20 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/07-job-control/expected.gitlab-ci.yml +17 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/07-job-control/input.yml +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/08-workflow-name/expected-report.json +13 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/08-workflow-name/expected.gitlab-ci.yml +14 -0
- package/src/migrate/from-github/fixtures/syntax-mapping/08-workflow-name/input.yml +7 -0
- package/src/migrate/from-github/fixtures.test.ts +92 -0
- package/src/migrate/from-github/index.ts +128 -0
- package/src/migrate/from-github/provenance.ts +68 -0
- package/src/migrate/from-github/rules.ts +82 -0
- package/src/migrate/from-github/stages.test.ts +99 -0
- package/src/migrate/from-github/stages.ts +177 -0
- package/src/migrate/from-github/transformer.test.ts +278 -0
- package/src/migrate/from-github/transformer.ts +719 -0
- package/src/migrate.mcp.test.ts +69 -0
- package/src/plugin.test.ts +7 -3
- package/src/plugin.ts +105 -1
- package/src/skills/chant-gitlab-migrate.md +117 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Migration fixtures
|
|
2
|
+
|
|
3
|
+
End-to-end test inputs for the `chant migrate` GitHub Actions →
|
|
4
|
+
GitLab CI/CD transformer.
|
|
5
|
+
|
|
6
|
+
Each fixture is a directory under `syntax-mapping/` or
|
|
7
|
+
`marketplace-actions/` with three files:
|
|
8
|
+
|
|
9
|
+
- `input.yml` — the GitHub Actions workflow under translation
|
|
10
|
+
- `expected.gitlab-ci.yml` — the GitLab CI/CD YAML the transformer
|
|
11
|
+
should produce (canonicalised compare; parse → stringify on both sides)
|
|
12
|
+
- `expected-report.json` — the *shape* of the diagnostic + provenance
|
|
13
|
+
report (totals, rule IDs, NeedsReview line/rule pairs). Asserts
|
|
14
|
+
structure rather than raw SARIF text so cosmetic provenance message
|
|
15
|
+
changes don't cause churn.
|
|
16
|
+
|
|
17
|
+
The driver test (`fixtures.test.ts`) globs the tree and runs every
|
|
18
|
+
fixture through `transform()`. To add a new fixture, drop a directory
|
|
19
|
+
with the three files; no manifest edits required.
|
|
20
|
+
|
|
21
|
+
## Attribution
|
|
22
|
+
|
|
23
|
+
The before/after content is derived from the upstream GitLab skill
|
|
24
|
+
`gitlab-org/ci-cd/github-actions-to-gitlab-ci` (MIT-licensed) —
|
|
25
|
+
specifically its `references/syntax-mapping.md` and
|
|
26
|
+
`references/marketplace-actions.md` files. See
|
|
27
|
+
`../../../ATTRIBUTIONS.md` for full credit.
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 0,
|
|
5
|
+
"info": 1
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"ACT-actions-checkout"
|
|
9
|
+
],
|
|
10
|
+
"needsReview": [],
|
|
11
|
+
"provenance": {
|
|
12
|
+
"literalRewrites": 2,
|
|
13
|
+
"actionMappings": [
|
|
14
|
+
{
|
|
15
|
+
"action": "actions/setup-node",
|
|
16
|
+
"tier": 1
|
|
17
|
+
}
|
|
18
|
+
]
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- build
|
|
5
|
+
workflow:
|
|
6
|
+
rules:
|
|
7
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
8
|
+
|
|
9
|
+
build:
|
|
10
|
+
image: node:20
|
|
11
|
+
cache:
|
|
12
|
+
key:
|
|
13
|
+
files:
|
|
14
|
+
- package-lock.json
|
|
15
|
+
paths:
|
|
16
|
+
- .npm/
|
|
17
|
+
script:
|
|
18
|
+
- npm ci
|
|
19
|
+
- npm test
|
|
20
|
+
stage: build
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 0,
|
|
5
|
+
"info": 1
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"ACT-actions-checkout"
|
|
9
|
+
],
|
|
10
|
+
"needsReview": [],
|
|
11
|
+
"provenance": {
|
|
12
|
+
"literalRewrites": 2,
|
|
13
|
+
"actionMappings": [
|
|
14
|
+
{
|
|
15
|
+
"action": "actions/setup-python",
|
|
16
|
+
"tier": 1
|
|
17
|
+
}
|
|
18
|
+
]
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- test
|
|
5
|
+
workflow:
|
|
6
|
+
rules:
|
|
7
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
8
|
+
|
|
9
|
+
test:
|
|
10
|
+
image: python:3.12
|
|
11
|
+
cache:
|
|
12
|
+
paths:
|
|
13
|
+
- .cache/pip/
|
|
14
|
+
script:
|
|
15
|
+
- pip install -r requirements.txt
|
|
16
|
+
- pytest
|
|
17
|
+
stage: test
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 0,
|
|
5
|
+
"info": 1
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"ACT-actions-checkout"
|
|
9
|
+
],
|
|
10
|
+
"needsReview": [],
|
|
11
|
+
"provenance": {
|
|
12
|
+
"literalRewrites": 2,
|
|
13
|
+
"actionMappings": [
|
|
14
|
+
{
|
|
15
|
+
"action": "docker/login-action",
|
|
16
|
+
"tier": 1
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"action": "docker/build-push-action",
|
|
20
|
+
"tier": 1
|
|
21
|
+
}
|
|
22
|
+
]
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- deploy
|
|
5
|
+
workflow:
|
|
6
|
+
rules:
|
|
7
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
8
|
+
|
|
9
|
+
publish:
|
|
10
|
+
image: docker:latest
|
|
11
|
+
services:
|
|
12
|
+
- name: docker:dind
|
|
13
|
+
alias: docker
|
|
14
|
+
variables:
|
|
15
|
+
DOCKER_TLS_CERTDIR: /certs
|
|
16
|
+
script:
|
|
17
|
+
- docker login -u ${{ github.actor }} -p ${{ secrets.GITHUB_TOKEN }} ghcr.io
|
|
18
|
+
- docker build -f Dockerfile -t ghcr.io/me/img:latest .
|
|
19
|
+
- docker push ghcr.io/me/img:latest
|
|
20
|
+
stage: deploy
|
package/src/migrate/from-github/fixtures/marketplace-actions/tier-1/docker-build-push/input.yml
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
on: push
|
|
2
|
+
jobs:
|
|
3
|
+
publish:
|
|
4
|
+
runs-on: ubuntu-latest
|
|
5
|
+
steps:
|
|
6
|
+
- uses: actions/checkout@v4
|
|
7
|
+
- uses: docker/login-action@v3
|
|
8
|
+
with:
|
|
9
|
+
registry: ghcr.io
|
|
10
|
+
username: ${{ github.actor }}
|
|
11
|
+
password: ${{ secrets.GITHUB_TOKEN }}
|
|
12
|
+
- uses: docker/build-push-action@v5
|
|
13
|
+
with:
|
|
14
|
+
context: .
|
|
15
|
+
push: true
|
|
16
|
+
tags: ghcr.io/me/img:latest
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 0,
|
|
5
|
+
"info": 1
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"ACT-actions-checkout"
|
|
9
|
+
],
|
|
10
|
+
"needsReview": [],
|
|
11
|
+
"provenance": {
|
|
12
|
+
"literalRewrites": 4,
|
|
13
|
+
"actionMappings": [
|
|
14
|
+
{
|
|
15
|
+
"action": "actions/upload-artifact",
|
|
16
|
+
"tier": 1
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"action": "actions/download-artifact",
|
|
20
|
+
"tier": 1
|
|
21
|
+
}
|
|
22
|
+
]
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- build
|
|
5
|
+
- test
|
|
6
|
+
workflow:
|
|
7
|
+
rules:
|
|
8
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
9
|
+
|
|
10
|
+
build:
|
|
11
|
+
image: ubuntu:24.04
|
|
12
|
+
artifacts:
|
|
13
|
+
paths:
|
|
14
|
+
- dist/
|
|
15
|
+
name: dist
|
|
16
|
+
expire_in: '7 days'
|
|
17
|
+
script:
|
|
18
|
+
- make build
|
|
19
|
+
stage: build
|
|
20
|
+
|
|
21
|
+
test:
|
|
22
|
+
image: ubuntu:24.04
|
|
23
|
+
needs:
|
|
24
|
+
- build
|
|
25
|
+
script:
|
|
26
|
+
- ./dist/app --test
|
|
27
|
+
stage: test
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
on: push
|
|
2
|
+
jobs:
|
|
3
|
+
build:
|
|
4
|
+
runs-on: ubuntu-latest
|
|
5
|
+
steps:
|
|
6
|
+
- uses: actions/checkout@v4
|
|
7
|
+
- run: make build
|
|
8
|
+
- uses: actions/upload-artifact@v4
|
|
9
|
+
with:
|
|
10
|
+
name: dist
|
|
11
|
+
path: dist/
|
|
12
|
+
retention-days: 7
|
|
13
|
+
test:
|
|
14
|
+
runs-on: ubuntu-latest
|
|
15
|
+
needs: build
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/download-artifact@v4
|
|
18
|
+
with:
|
|
19
|
+
name: dist
|
|
20
|
+
- run: ./dist/app --test
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 0,
|
|
5
|
+
"info": 1
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"ACT-actions-checkout"
|
|
9
|
+
],
|
|
10
|
+
"needsReview": [],
|
|
11
|
+
"provenance": {
|
|
12
|
+
"literalRewrites": 2,
|
|
13
|
+
"actionMappings": [
|
|
14
|
+
{
|
|
15
|
+
"action": "actions/setup-node",
|
|
16
|
+
"tier": 1
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"action": "codecov/codecov-action",
|
|
20
|
+
"tier": 2
|
|
21
|
+
}
|
|
22
|
+
]
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- test
|
|
5
|
+
workflow:
|
|
6
|
+
rules:
|
|
7
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
8
|
+
|
|
9
|
+
test:
|
|
10
|
+
image: node:22
|
|
11
|
+
script:
|
|
12
|
+
- npm test
|
|
13
|
+
- pip install codecov-cli
|
|
14
|
+
- codecovcli upload-process --file ./coverage.xml --token $CODECOV_TOKEN
|
|
15
|
+
stage: test
|
package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/setup-bun/expected-report.json
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 0,
|
|
5
|
+
"info": 1
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"ACT-actions-checkout"
|
|
9
|
+
],
|
|
10
|
+
"needsReview": [],
|
|
11
|
+
"provenance": {
|
|
12
|
+
"literalRewrites": 2,
|
|
13
|
+
"actionMappings": [
|
|
14
|
+
{
|
|
15
|
+
"action": "oven-sh/setup-bun",
|
|
16
|
+
"tier": 2
|
|
17
|
+
}
|
|
18
|
+
]
|
|
19
|
+
}
|
|
20
|
+
}
|
package/src/migrate/from-github/fixtures/marketplace-actions/tier-2/setup-bun/expected.gitlab-ci.yml
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- build
|
|
5
|
+
workflow:
|
|
6
|
+
rules:
|
|
7
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
8
|
+
|
|
9
|
+
build:
|
|
10
|
+
image: oven/bun:latest
|
|
11
|
+
cache:
|
|
12
|
+
paths:
|
|
13
|
+
- .bun/install/cache/
|
|
14
|
+
script:
|
|
15
|
+
- bun install
|
|
16
|
+
- bun test
|
|
17
|
+
stage: build
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 1,
|
|
5
|
+
"info": 1
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"ACT-actions-checkout",
|
|
9
|
+
"ACT-dorny-paths-filter"
|
|
10
|
+
],
|
|
11
|
+
"needsReview": [
|
|
12
|
+
{
|
|
13
|
+
"line": 1,
|
|
14
|
+
"ruleId": "ACT-dorny-paths-filter"
|
|
15
|
+
}
|
|
16
|
+
],
|
|
17
|
+
"provenance": {
|
|
18
|
+
"literalRewrites": 2,
|
|
19
|
+
"actionMappings": []
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- build
|
|
5
|
+
workflow:
|
|
6
|
+
rules:
|
|
7
|
+
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
|
|
8
|
+
|
|
9
|
+
detect:
|
|
10
|
+
image: ubuntu:24.04
|
|
11
|
+
script:
|
|
12
|
+
- '# dorny/paths-filter has no script equivalent in GitLab.'
|
|
13
|
+
- '# Use rules:changes: on each job to gate on file path changes.'
|
|
14
|
+
- '# Example: rules: [{ changes: [''src/backend/**''] }]'
|
|
15
|
+
stage: build
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"totals": {
|
|
3
|
+
"error": 0,
|
|
4
|
+
"warning": 1,
|
|
5
|
+
"info": 0
|
|
6
|
+
},
|
|
7
|
+
"ruleIds": [
|
|
8
|
+
"MIG-ON-SCHEDULE"
|
|
9
|
+
],
|
|
10
|
+
"needsReview": [
|
|
11
|
+
{
|
|
12
|
+
"line": 1,
|
|
13
|
+
"ruleId": "MIG-ON-SCHEDULE"
|
|
14
|
+
}
|
|
15
|
+
],
|
|
16
|
+
"provenance": {
|
|
17
|
+
"literalRewrites": 4,
|
|
18
|
+
"actionMappings": []
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- build
|
|
5
|
+
workflow:
|
|
6
|
+
name: CI
|
|
7
|
+
rules:
|
|
8
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
9
|
+
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
|
|
10
|
+
- if: '$CI_PIPELINE_SOURCE == "schedule"'
|
|
11
|
+
|
|
12
|
+
build:
|
|
13
|
+
image: ubuntu:24.04
|
|
14
|
+
script:
|
|
15
|
+
- make build
|
|
16
|
+
stage: build
|
package/src/migrate/from-github/fixtures/syntax-mapping/02-stages-needs/expected.gitlab-ci.yml
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- build
|
|
5
|
+
- test
|
|
6
|
+
- deploy
|
|
7
|
+
workflow:
|
|
8
|
+
rules:
|
|
9
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
10
|
+
|
|
11
|
+
build:
|
|
12
|
+
image: ubuntu:24.04
|
|
13
|
+
script:
|
|
14
|
+
- make build
|
|
15
|
+
stage: build
|
|
16
|
+
|
|
17
|
+
deploy:
|
|
18
|
+
image: ubuntu:24.04
|
|
19
|
+
needs:
|
|
20
|
+
- test
|
|
21
|
+
script:
|
|
22
|
+
- make deploy
|
|
23
|
+
stage: deploy
|
|
24
|
+
|
|
25
|
+
test:
|
|
26
|
+
image: ubuntu:24.04
|
|
27
|
+
needs:
|
|
28
|
+
- build
|
|
29
|
+
script:
|
|
30
|
+
- make test
|
|
31
|
+
stage: test
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- test
|
|
5
|
+
workflow:
|
|
6
|
+
rules:
|
|
7
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
8
|
+
|
|
9
|
+
test:
|
|
10
|
+
image: ubuntu:24.04
|
|
11
|
+
parallel:
|
|
12
|
+
matrix:
|
|
13
|
+
- OS: '[ubuntu, debian]'
|
|
14
|
+
NODE:
|
|
15
|
+
- 18
|
|
16
|
+
- 20
|
|
17
|
+
- 22
|
|
18
|
+
script:
|
|
19
|
+
- echo "Testing on $os with Node $node"
|
|
20
|
+
stage: test
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Generated by chant migrate from input.yml
|
|
2
|
+
|
|
3
|
+
stages:
|
|
4
|
+
- build
|
|
5
|
+
variables:
|
|
6
|
+
GREETING: Hello
|
|
7
|
+
workflow:
|
|
8
|
+
rules:
|
|
9
|
+
- if: '$CI_PIPELINE_SOURCE == "push"'
|
|
10
|
+
|
|
11
|
+
greet:
|
|
12
|
+
image: ubuntu:24.04
|
|
13
|
+
variables:
|
|
14
|
+
NAME: World
|
|
15
|
+
script:
|
|
16
|
+
- echo "$GREETING $NAME"
|
|
17
|
+
- echo "Token is $API_TOKEN"
|
|
18
|
+
stage: build
|