-
Notifications
You must be signed in to change notification settings - Fork 16
Variants changes #1473
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Variants changes #1473
Changes from all commits
Commits
Show all changes
2266 commits
Select commit
Hold shift + click to select a range
7e8fa28
Merge branch 'development' of github.com:contentstack/cli-variants in…
shafeeqd959 30e1ca9
Ui text updated
cs-raj 685f795
fix when entry does not have title or title is empty
cs-raj 720d7fb
Merge pull request #1385 from contentstack/fix/Ui-Text-Fixed
cs-raj 1543666
lock-file-update
cs-raj 02631a5
Merge pull request #1386 from contentstack/fix/lock-file-update
cs-raj 417d6b5
API key and branch name included in the header
antonyagustine b4e7739
Merge pull request #25 from contentstack/fix/variant-entry-fix
antonyagustine 11fd7f0
Merge pull request #1387 from contentstack/development
cs-raj 6ff5957
Fix: Headers added
antonyagustine 894af8f
Merge pull request #27 from contentstack/fix/variant-entry-import-fix
antonyagustine e7cb502
updated personalization url
shafeeqd959 223dd1a
Merge pull request #26 from contentstack/feat/CS-44627
shafeeqd959 22e5b2d
feat: Added Audit and audit fix for Select fields in entries and mino…
cs-raj aff8bff
Merge remote-tracking branch 'origin/development' into feat/CS-44502
cs-raj 261fec1
test: Variant entries export test,Unit test basic setup
antonyagustine c571eb4
Merge pull request #28 from contentstack/test/CS-44748-export
antonyagustine 9be37e2
PR fixes and version bump of CLI
cs-raj 22c0065
Merge pull request #1388 from contentstack/staging
cs-raj 3dae123
PR fixes
cs-raj dfd323f
Merge pull request #1390 from contentstack/main
cs-raj 43e8071
Merge pull request #1391 from contentstack/staging-to-development
cs-raj cf6466b
Merge branch 'development' into feat/CS-44502
cs-raj 826ac3b
PR fixes and lock-file update
cs-raj 39e0ad6
log removal
cs-raj 1b46298
Merge pull request #1389 from contentstack/feat/CS-44502
cs-raj a218749
test: Variant entries import unit test cases
antonyagustine 8c9e43a
Merge pull request #29 from contentstack/test/CS-44748-import
antonyagustine eba7675
fix: handle error in variant import
aman19K 00d4ea7
Merge pull request #30 from contentstack/fix/DX-488-variant-import
aman19K ed1dbe7
fix: resolved the asset publish issue caused by the multiple languages
aman19K 48ae308
Merge branch 'hotfix/DX-530' into hotfix/DX-530-stag
aman19K f9af75a
Merge pull request #1394 from contentstack/hotfix/DX-530-stag
cs-raj 93ea693
Merge pull request #1392 from contentstack/hotfix/DX-530
cs-raj be0140c
Merge branch 'main' into main-to-staging
cs-raj 9bda78a
lock-file and readme updated
cs-raj a5f5dfd
Merge pull request #1396 from contentstack/main-to-staging
cs-raj 818bc25
Merge branch 'staging' into staging-to-development
cs-raj f4aa123
Lock-file and readme update
cs-raj 6dd0125
Merge pull request #1398 from contentstack/staging-to-development
cs-raj 71e1309
fix: added success message for exporting experience
aman19K cbc09b9
Merge pull request #31 from contentstack/fix/DX-487-export-experience…
aman19K a471f03
added audit and audit fix for mandatory fields in Entries, and added …
cs-raj 62bb5c4
PR fixes and lock-file update
cs-raj 9b70237
PR comment fixes
cs-raj d2942ca
added condition to show extension updated message successfully, in ma…
cs-raj 70e5e46
formatting
cs-raj e5d823a
PR change
cs-raj c794718
displaying the audit report for the mandatory feilds in case of no pu…
cs-raj 905a28d
Merge pull request #1400 from contentstack/fix/DX-54
cs-raj 28e8eff
removing redundant checks
cs-raj 6495f46
Merge branch 'development' into feat/DX-523
cs-raj f20c73d
Merge pull request #1399 from contentstack/feat/DX-523
cs-raj 05ae5de
upgraded oclif/core to 3.26.5 and version bump
cs-raj 3337c1c
used the length property to validate the missing mandatory fields, av…
cs-raj 0d0da65
Merge pull request #1402 from contentstack/bugfix/DX-552
cs-raj df0badc
handled the case when Csdx context is not found
cs-raj 57f215d
lock-file update
cs-raj 68c35f2
Merge pull request #1403 from contentstack/fix/lock-files
cs-raj 56700b8
Merge pull request #1404 from contentstack/development
cs-raj 4b1d69b
Merge branch 'development' into feat/DX-524
cs-raj c933f81
feat: handled variant api errors
aman19K c633199
fix: attribute, audience, event & experience fail cases
aman19K d70f22d
revert dev url
aman19K 1514232
Merge pull request #32 from contentstack/feat/DX-317-handle-variant-a…
aman19K 12f3f87
updated personalization url to access in multiple region
shafeeqd959 9a5fd82
merged changes
shafeeqd959 c7c55f0
removed console
shafeeqd959 4e61e45
Merge pull request #33 from contentstack/feat/DX-502
shafeeqd959 b4c46ac
changed remove publish_details function and changed the logs for both…
cs-raj 5891dfa
formatting and used the previous function with changed name for publi…
cs-raj 580ddf6
lock-file update
cs-raj debd815
Merge pull request #1405 from contentstack/staging
cs-raj 3112f51
import and export version bump
cs-raj 5269873
Merge pull request #1406 from contentstack/fix/DX-92
cs-raj c1d3079
Merge pull request #1407 from contentstack/main
cs-raj e3620b3
Merge branch 'staging' into staging-to-development
cs-raj 69419c2
Back merge lock-file update
cs-raj bec9eb0
Merge pull request #1408 from contentstack/staging-to-development
cs-raj 9f737c7
Merge remote-tracking branch 'origin/development' into feat/DX-524
cs-raj 5ad0d3d
lock-file update
cs-raj 4b9fd62
Merge pull request #1401 from contentstack/feat/DX-524
cs-raj 1c94309
fix: issue with import entries arising from compact library
aman19K ed729dc
fix: typo
aman19K 5d6e248
Merge pull request #1409 from contentstack/fix/DX-591
aman19K dc28a4f
cli-command version bump
cs-raj 3e020a5
Merge branch 'development' into fix/version-bump
cs-raj 9a02c56
Merge pull request #1410 from contentstack/fix/version-bump
cs-raj 7e18eeb
Merge pull request #1411 from contentstack/development
cs-raj fe01905
SRE fixes
cs-raj 7a27156
fix path related issues
cs-raj 4fc06d6
variable update
cs-raj d5ce142
fixed Regex
cs-raj 5a2c782
sca-scan.yml
aravindbuilt 3b178f1
jira.yml
aravindbuilt 959455c
sast-scan.yml
aravindbuilt f0b86d4
Delete secrets-scan.yml
aravindbuilt 1d9304b
codeql-analysis.yml
aravindbuilt 495a6e6
fix auth issues
cs-raj 54ab51b
Resolved Regular expression DOS attacks and prototype pollution
cs-raj 4e72a14
Merge branch 'main' into main-to-stage
cs-raj b0d219f
Merge pull request #1413 from contentstack/main-to-stage
cs-raj 1e3cbef
Merge pull request #1414 from contentstack/staging-to-development
cs-raj 813ff16
fix: variant import & handle import error
aman19K c88e713
version bump and reverted changes for asset url
cs-raj da69139
fix: import logger issue
aman19K 7f0bd30
Merge branch 'development' into fix/DX-94
cs-raj d834c01
removed unsed regex
cs-raj d304357
refactor: create variant entry
aman19K b6fd2c9
fix: variant entries list check
aman19K d86ca8d
refactor: variant import error handling
aman19K b5e9497
Merge pull request #34 from contentstack/fix/Dx-581-import-variant-en…
aman19K ee30df6
fix: asset import & variant export issue
aman19K 3376c69
Merge pull request #35 from contentstack/fix/DX-624
aman19K 2f395a5
PR fixes and formating
cs-raj 7a053f0
adding sanitize path in callsite
cs-raj ce3816f
typo error
cs-raj 16b5e12
Merge pull request #1415 from contentstack/fix/DX-94
cs-raj 5710ef8
feat: implemented entry variants publish
aman19K 30d8fe0
fix: variant uid mapper
aman19K a69c7e5
fix: entries mapper issue
aman19K a9ff25d
fix: variant publish issue
aman19K 5621e3d
formatting & doc
aman19K f05af8a
Merge pull request #36 from contentstack/feat/DX-319-variant-entries-…
aman19K 077ed4d
fixed the generating tree structure for the assets during branches merge
cs-raj 202d3e0
fix: handled log message if stack not connected with any project
aman19K 5f579be
Merge pull request #37 from contentstack/fix/DX-650
aman19K f54fd8a
Merge pull request #1416 from contentstack/fix/DX-525
cs-raj 08f70af
Merge pull request #1412 from contentstack/staging
cs-raj 9a3aaa7
fixed content type attaching in experience, empty entry variants fold…
shafeeqd959 e3ed6ee
Merge pull request #38 from contentstack/fix/DX-579/DX-580
shafeeqd959 4322cf7
Merge pull request #1417 from contentstack/main
cs-raj 16ea0f1
added variant success file
aman19K f1e72ee
revert dev url
aman19K 4e7c1ec
Merge branch 'staging' into staging-to-development
cs-raj f07d6af
Merge pull request #1419 from contentstack/staging-to-development
cs-raj 1e2630c
handle failed entry variant case
aman19K cde5833
added variant uid in publish logger msg
aman19K 25a329f
Merge pull request #39 from contentstack/fix/variant-success-file
aman19K 79cd09f
fix: variant folder issues & added personalization module check befor…
aman19K 4251b8d
refactor: default personalization disabled
aman19K c8e800f
Merge pull request #40 from contentstack/fix/DX-676
aman19K 3a337a8
Merge pull request #1420 from contentstack/development
harshithad0703 5929828
fix: Handled pagination during the script creation
cs-raj fc10e46
minor version bump
cs-raj 15dc431
variable declaration fix
cs-raj 5578d6c
fixed the issues with rich text type and bugs in entries helper
cs-raj 831fd0d
fix: handle deprecation warning message
aman19K e3d4694
Merge pull request #1422 from contentstack/bugfix/DX-717
cs-raj d93a129
Merge remote-tracking branch 'origin/development' into fix/DX-647
cs-raj 811cf3a
fixed the entry migration script for contentTypes
cs-raj 301d39f
Merge pull request #1424 from contentstack/fix/dev
cs-raj f57d92b
Merge branch 'development' into fix/DX-647
cs-raj 7df5a10
Merge pull request #1423 from contentstack/fix/DX-647
cs-raj c6c48f6
Implemented compass app integration with Seed and Bootstrap command (…
sunil-lakshman 90dc8cc
Merge branch 'development' into fix/DX-51/deprecation-warning
aman19K 997c9f9
Merge pull request #1427 from contentstack/fix/DX-51/deprecation-warning
aman19K 23570d0
Merge pull request #1421 from contentstack/staging
harshithad0703 5fd14eb
Merge pull request #1428 from contentstack/main
harshithad0703 b2cab26
Merge branch 'staging' into staging-to-development
harshithad0703 299451b
Merge pull request #1429 from contentstack/staging-to-development
harshithad0703 18d4878
fixed entry variant import for file fields and fixed project name dup…
shafeeqd959 284691f
added project flag
shafeeqd959 314402a
Merge pull request #41 from contentstack/fix/DX-643/DX-644
shafeeqd959 f56882c
fix: added rte field missing fix
6320ee5
feat: Added two flags for excluding the global modules and one for pr…
cs-raj dfa3ffd
fix: Reverted bootstrap changes
cs-raj 6c0f65d
Merge pull request #1432 from contentstack/revert/changes
cs-raj 87d1f6e
Merge pull request #1433 from contentstack/development
cs-raj bbcf41c
fixed project creation
shafeeqd959 6af75a1
Merge pull request #42 from contentstack/fix/DX-643/DX-644
shafeeqd959 7bb65e3
added prompt for mapper directory
cs-raj d1710ae
only webhooks are excluded
cs-raj cac073d
Merge remote-tracking branch 'origin/development' into feat/DX-56
cs-raj 329f17b
lock-file update
cs-raj efd2b91
pnpm file update
cs-raj 87da972
Merge remote-tracking branch 'origin/development' into feat/DX-56
cs-raj 22e519e
version bump
cs-raj 6aeac45
removed unused code
cs-raj 0b5ae6d
PR fix
cs-raj 0384d6d
Removed mapper directory
cs-raj 6f954f3
chore: upgraded marketplace sdk package
harshithad0703 0611639
version bump
harshithad0703 51fe246
final PR changes !
cs-raj 038ba89
Merge pull request #1431 from contentstack/feat/DX-56
cs-raj 7dcddb0
Merge branch 'development' into fix/DX-775-upgrade-marketplace-sdk
harshithad0703 f013d58
Merge pull request #1435 from contentstack/fix/DX-775-upgrade-marketp…
harshithad0703 a5cc115
chore: version bump
harshithad0703 35cafdc
Merge branch 'development' into fix/DX-775-upgrade-marketplace-sdk
harshithad0703 226ddcd
Merge pull request #1436 from contentstack/fix/DX-775-upgrade-marketp…
harshithad0703 5aad9bc
Merge pull request #1434 from contentstack/staging
cs-raj c9fed8b
Merge pull request #1437 from contentstack/main
cs-raj 06c0c06
Merge remote-tracking branch 'origin/staging' into stage-to-development
cs-raj 89d4961
lock-file update
cs-raj ceab81a
Merge pull request #1439 from contentstack/stage-to-development
cs-raj fa7ab5f
fix: removed rteCTs check
754cdd8
Merge branch 'development' into fix/DX-606
cs-raj ab5f5f8
Merge pull request #1430 from contentstack/fix/DX-606
aman19K 079934e
fix: handle taxonomy & environment mapper issue
aman19K 6d3715e
Merge pull request #1440 from contentstack/fix/DX-803-mapper-issue
aman19K c237921
fixed the failing of audit when no publish details were found and del…
cs-raj 8768dfa
Ui text updates
cs-raj d2c8334
fixed management token on variants, fixed asset reference handling is…
shafeeqd959 e93aba1
Merge pull request #1442 from contentstack/staging
cs-raj f646893
Merge pull request #43 from contentstack/fix/DX-777,DX-778
shafeeqd959 36af104
Merge branch 'development' into fix/DX-829
cs-raj c0b9a8f
Merge pull request #1441 from contentstack/fix/DX-829
cs-raj 3f4a6da
Merge pull request #1443 from contentstack/main
cs-raj 7960e93
Merge branch 'staging' into staging-to-development
cs-raj fd080f0
lock file update
cs-raj 44f160c
Merge pull request #1444 from contentstack/staging-to-development
cs-raj e0c9650
chore: upgraded marketplace package in cli-utilities
harshithad0703 1bb6b30
Merge pull request #1445 from contentstack/fix/DX-809-marketplace-ver…
harshithad0703 d5db2e4
chore: upgraded cli-utilities package to 1.6.3
harshithad0703 6000534
Merge pull request #1448 from contentstack/fix/DX-809-marketplace-ver…
harshithad0703 d25ed1d
fixed the snyk code issues
cs-raj 490dbd2
version bump
cs-raj 40fcae6
Merge remote-tracking branch 'origin/development' into fix/DX-787
cs-raj 5cff427
Removed the branches test file
cs-raj 58a6e11
removed the js changes and removed pattern
cs-raj b2f760c
pr fixes
cs-raj 4b8c0c2
Merge pull request #1450 from contentstack/fix/DX-787
cs-raj 82f703a
Merge branch 'development' of github.com:contentstack/cli into next-f…
shafeeqd959 28d3846
Merge branch 'development' of github.com:contentstack/cli into next-f…
shafeeqd959 548dcf4
merged latest cli changes
shafeeqd959 5ffd2cd
updated config
shafeeqd959 c80e9a5
Merge branch 'next-feature-update' of github.com:contentstack/cli int…
shafeeqd959 ac956ce
Merge branch 'development' of github.com:contentstack/cli into next-f…
shafeeqd959 791b437
Merge remote-tracking branch 'upstream/next-feature-update' into late…
shafeeqd959 a2265e1
fixed mapper folder creation for projects
shafeeqd959 5205b27
Merge branch 'development' of github.com:contentstack/cli into next-f…
shafeeqd959 75b08a5
Merge remote-tracking branch 'upstream/next-feature-update' into late…
shafeeqd959 ba1fcb1
Merge branch 'development' of github.com:contentstack/cli into next-f…
shafeeqd959 2d5c40a
updated message
shafeeqd959 7989b77
latest change
shafeeqd959 9e7d300
personalize api update for contentype attachment
shafeeqd959 7216afb
cma config check in adapter
shafeeqd959 a311b2e
axios upgraded
shafeeqd959 19f016d
Merge pull request #1519 from contentstack/feat/DX-1130,DX-1133
shafeeqd959 c0508c5
merged changes
shafeeqd959 aabcd37
changes
shafeeqd959 7748f2d
removed secrets scan
shafeeqd959 514b944
Merge branch 'development' of github.com:contentstack/cli into next-f…
shafeeqd959 6d2f4c6
latest updates
shafeeqd959 9757f3a
Merge branch 'staging' of github.com:contentstack/cli into next-featu…
shafeeqd959 c9fcaa9
updated code to check environment support/ provided the url for perso…
shafeeqd959 8ab75df
bumped version
shafeeqd959 fe2d737
Merge branch 'staging' of github.com:contentstack/cli into next-featu…
shafeeqd959 ea62b3e
lastest changes
shafeeqd959 3726f57
Merge branch 'staging' of github.com:contentstack/cli into next-featu…
shafeeqd959 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
58 changes: 58 additions & 0 deletions
58
packages/contentstack-export/src/export/modules/personalization.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,58 @@ | ||
| import { | ||
| ExportProjects, | ||
| ExportExperiences, | ||
| ExportEvents, | ||
| ExportAttributes, | ||
| ExportAudiences, | ||
| AnyProperty, | ||
| } from '@contentstack/cli-variants'; | ||
|
|
||
| import { log, formatError } from '../../utils'; | ||
| import { ModuleClassParams, ExportConfig } from '../../types'; | ||
|
|
||
| export default class ExportPersonalization { | ||
| public exportConfig: ExportConfig; | ||
| public personalizeConfig: { dirName: string; baseURL: Record<string, string> } & AnyProperty; | ||
| constructor({ exportConfig }: ModuleClassParams) { | ||
| this.exportConfig = exportConfig; | ||
| this.personalizeConfig = exportConfig.modules.personalization; | ||
| } | ||
|
|
||
| async start(): Promise<void> { | ||
| try { | ||
| if (!this.personalizeConfig.baseURL[this.exportConfig.region.name]) { | ||
| log(this.exportConfig, 'Skipping Personalize project export, personalize url is not set', 'info'); | ||
| this.exportConfig.personalizationEnabled = false; | ||
| return; | ||
| } | ||
| if (this.exportConfig.management_token) { | ||
| log(this.exportConfig, 'Skipping Personalize project export when using management token', 'info'); | ||
| this.exportConfig.personalizationEnabled = false; | ||
| return; | ||
| } | ||
| await new ExportProjects(this.exportConfig).start(); | ||
| if (this.exportConfig.personalizationEnabled) { | ||
| const moduleMapper = { | ||
| events: new ExportEvents(this.exportConfig), | ||
| attributes: new ExportAttributes(this.exportConfig), | ||
| audiences: new ExportAudiences(this.exportConfig), | ||
| experiences: new ExportExperiences(this.exportConfig), | ||
| }; | ||
|
|
||
| const order: (keyof typeof moduleMapper)[] = this.exportConfig.modules.personalization | ||
| .exportOrder as (keyof typeof moduleMapper)[]; | ||
|
|
||
| for (const module of order) { | ||
| if (moduleMapper[module]) { | ||
| await moduleMapper[module].start(); | ||
| } else { | ||
| log(this.exportConfig, `No implementation found for the module ${module}`, 'info'); | ||
| } | ||
| } | ||
| } | ||
| } catch (error) { | ||
| this.exportConfig.personalizationEnabled = false; | ||
| log(this.exportConfig, error, 'error'); | ||
| } | ||
| } | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.