@cerema/cadriciel 1.4.39 → 1.5.0
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/cli/global/doc.js +1 -1
- package/cli/global/init.js +10 -11
- package/cli/global/load.js +10 -12
- package/cli.js +1 -1
- package/package.json +1 -1
package/cli/global/doc.js
CHANGED
package/cli/global/init.js
CHANGED
|
@@ -62,16 +62,15 @@ Host cadriciel
|
|
|
62
62
|
fs.mkdirSync(userHome + '/.ssh');
|
|
63
63
|
} catch (e) {}
|
|
64
64
|
try {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
}
|
|
65
|
+
var ssh = fs.readFileSync(userHome + '/.ssh/config', 'utf-8');
|
|
66
|
+
} catch (e) {
|
|
67
|
+
var ssh = '';
|
|
68
|
+
}
|
|
69
|
+
if (!ssh.includes('87c7dfbf-172a-4084-a862-4a23f35a5b79 ')) {
|
|
70
|
+
ssh += '\n\n' + sshtemplate;
|
|
71
|
+
fs.writeFileSync(userHome + '/.ssh/config', ssh, { flag: 'a' });
|
|
72
|
+
fs.chmodSync(userHome + '/.ssh/config', 0o600);
|
|
73
|
+
}
|
|
75
74
|
} catch (e) {
|
|
76
75
|
console.log(e);
|
|
77
76
|
error(
|
|
@@ -166,7 +165,7 @@ Host cadriciel
|
|
|
166
165
|
|
|
167
166
|
💻 ${chalk.bold('Pour manager votre projet :')}
|
|
168
167
|
|
|
169
|
-
👉 ${link('studio.
|
|
168
|
+
👉 ${link('studio.cerema.dev', 'studio.cerema.dev')}
|
|
170
169
|
|
|
171
170
|
──────────────────────────────────────────────────────────────`);
|
|
172
171
|
console.log(' ');
|
package/cli/global/load.js
CHANGED
|
@@ -37,16 +37,15 @@ module.exports = (args) => {
|
|
|
37
37
|
fs.mkdirSync(userHome + '/.ssh');
|
|
38
38
|
} catch (e) {}
|
|
39
39
|
try {
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
}
|
|
40
|
+
var ssh = fs.readFileSync(userHome + '/.ssh/config', 'utf-8');
|
|
41
|
+
} catch (e) {
|
|
42
|
+
var ssh = '';
|
|
43
|
+
}
|
|
44
|
+
if (!ssh.includes('87c7dfbf-172a-4084-a862-4a23f35a5b79 ')) {
|
|
45
|
+
ssh += '\n\n' + sshtemplate;
|
|
46
|
+
fs.writeFileSync(userHome + '/.ssh/config', ssh, { flag: 'a' });
|
|
47
|
+
fs.chmodSync(userHome + '/.ssh/config', 0o600);
|
|
48
|
+
}
|
|
50
49
|
} catch (e) {
|
|
51
50
|
console.log(e);
|
|
52
51
|
error(
|
|
@@ -64,7 +63,6 @@ Host cadriciel
|
|
|
64
63
|
# -----------------------------------------------------
|
|
65
64
|
`;
|
|
66
65
|
|
|
67
|
-
|
|
68
66
|
/** loading the project */
|
|
69
67
|
const load = async (uri, title) => {
|
|
70
68
|
console.log(' ');
|
|
@@ -132,7 +130,7 @@ Host cadriciel
|
|
|
132
130
|
|
|
133
131
|
💻 ${chalk.bold('Pour manager votre projet :')}
|
|
134
132
|
|
|
135
|
-
👉 ${link('studio.
|
|
133
|
+
👉 ${link('studio.cerema.dev', 'studio.cerema.dev')}
|
|
136
134
|
|
|
137
135
|
──────────────────────────────────────────────────────────────`);
|
|
138
136
|
console.log(' ');
|
package/cli.js
CHANGED
|
@@ -12,7 +12,7 @@ const boxen = require('boxen'); // For creating boxes in the console.
|
|
|
12
12
|
// Locating the '.cadriciel' directory starting from the current working directory.
|
|
13
13
|
const CADRICIEL_PATH = findCadricielDir(process.cwd());
|
|
14
14
|
const CADRICIEL_COMMAND = 'cad';
|
|
15
|
-
global.CADRICIEL_URI = 'https://cadriciel.
|
|
15
|
+
global.CADRICIEL_URI = 'https://cadriciel.cerema.dev/api';
|
|
16
16
|
//global.CADRICIEL_URI = 'http://localhost:3000/api';
|
|
17
17
|
|
|
18
18
|
// Initialize command storage objects.
|