Skip to content

Commit

Permalink
[8.x] SKA: Relocate script 6.1 (#205086) (#205092)
Browse files Browse the repository at this point in the history
# Backport

This will backport the following commits from `main` to `8.x`:
- [SKA: Relocate script 6.1
(#205086)](#205086)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Gerard
Soldevila","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-12-23T14:17:44Z","message":"SKA:
Relocate script 6.1 (#205086)\n\n## Summary\r\n\r\n* Exclude example
modules from relocation.\r\n* Add an extra path transform to simplify
packages
folders.","sha":"19f24b31d9dec5ec6d6c97a9bcbcd26657f181e8","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Core","release_note:skip","v9.0.0","backport:prev-minor","plugin
groups"],"title":"SKA: Relocate script
6.1","number":205086,"url":"https://github.com/elastic/kibana/pull/205086","mergeCommit":{"message":"SKA:
Relocate script 6.1 (#205086)\n\n## Summary\r\n\r\n* Exclude example
modules from relocation.\r\n* Add an extra path transform to simplify
packages
folders.","sha":"19f24b31d9dec5ec6d6c97a9bcbcd26657f181e8"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/205086","number":205086,"mergeCommit":{"message":"SKA:
Relocate script 6.1 (#205086)\n\n## Summary\r\n\r\n* Exclude example
modules from relocation.\r\n* Add an extra path transform to simplify
packages folders.","sha":"19f24b31d9dec5ec6d6c97a9bcbcd26657f181e8"}}]}]
BACKPORT-->

Co-authored-by: Gerard Soldevila <[email protected]>
  • Loading branch information
kibanamachine and gsoldevila authored Dec 23, 2024
1 parent a2e64e0 commit f08b07a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/kbn-relocate/relocate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,13 @@ const findModules = ({ teams, paths, included, excluded }: FindModulesParams, lo
.filter(({ manifest }) => !manifest.devOnly)
// explicit exclusions
.filter(({ id }) => !EXCLUDED_MODULES.includes(id) && !excluded.includes(id))
// we don't want to move test modules (just yet)
// we don't want to move test and example modules (just yet)
.filter(
({ directory }) =>
!directory.includes(`/${KIBANA_FOLDER}/test/`) &&
!directory.includes(`/${KIBANA_FOLDER}/x-pack/test/`)
!directory.includes(`/${KIBANA_FOLDER}/x-pack/test/`) &&
!directory.includes(`/${KIBANA_FOLDER}/examples/`) &&
!directory.includes(`/${KIBANA_FOLDER}/x-pack/examples/`)
)
// the module is under the umbrella specified by the user
.filter(
Expand Down
2 changes: 2 additions & 0 deletions packages/kbn-relocate/utils/transforms.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ const TRANSFORMS: Record<string, string | TransformFunction> = {
'x-pack/solutions/security/packages/security-solution/': 'x-pack/solutions/security/packages/',
'x-pack/solutions/observability/plugins/observability_solution/':
'x-pack/solutions/observability/plugins/',
'x-pack/solutions/observability/packages/observability/observability_utils/observability_':
'x-pack/solutions/observability/packages/',
'x-pack/solutions/observability/packages/observability/':
'x-pack/solutions/observability/packages/',
'src/core/packages/core/': (path: string) => {
Expand Down

0 comments on commit f08b07a

Please sign in to comment.