@kradle/cli 0.0.3 → 0.0.4
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.
|
@@ -50,9 +50,9 @@ export default class Create extends Command {
|
|
|
50
50
|
task: async (_, task) => {
|
|
51
51
|
const challengeData = await api.getChallenge(args.challenge);
|
|
52
52
|
// Remove fields that shouldn't be in the config file
|
|
53
|
-
const { id, creationTime, updateTime, creator,
|
|
53
|
+
const { id, creationTime, updateTime, creator, ...cleanChallenge } = challengeData;
|
|
54
54
|
// We remove the username prefix from the slug, to make the challenge easy to share with others
|
|
55
|
-
|
|
55
|
+
cleanChallenge.slug = cleanChallenge.slug.split(":")[1];
|
|
56
56
|
// Remove quotes from keys
|
|
57
57
|
const configStr = JSON.stringify(cleanChallenge, null, 2).replace(/"([a-zA-Z0-9_]+)":/g, "$1:");
|
|
58
58
|
await fs.writeFile(challenge.configPath, `
|
package/oclif.manifest.json
CHANGED