propagate-cli 1.9.20 → 1.9.22
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 +20 -22
- package/bin/action/help.js +20 -22
- package/bin/main.js +14 -12
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -82,53 +82,51 @@ If you would like to contribute or would simply like to have a look at the code,
|
|
|
82
82
|
Propagate has the following commands and options:
|
|
83
83
|
|
|
84
84
|
```
|
|
85
|
-
propagate
|
|
85
|
+
propagate [<options>] Propagate the current package
|
|
86
86
|
|
|
87
|
-
propagate <sub-directory>
|
|
88
|
-
|
|
89
|
-
propagate <command>
|
|
87
|
+
propagate [<options>] <sub-directory> Propagate a package in the given sub-directory
|
|
90
88
|
|
|
91
89
|
propagate [<command>] [<options>]
|
|
92
90
|
|
|
93
91
|
Commands:
|
|
94
92
|
|
|
95
|
-
version
|
|
93
|
+
version Show the version
|
|
96
94
|
|
|
97
|
-
help
|
|
95
|
+
help Show this help
|
|
98
96
|
|
|
99
|
-
initialise
|
|
97
|
+
initialise Create a configuration file
|
|
100
98
|
|
|
101
|
-
add-directory
|
|
99
|
+
add-directory Add an additional directory
|
|
102
100
|
|
|
103
|
-
remove-directory
|
|
101
|
+
remove-directory Remove an additional directory
|
|
104
102
|
|
|
105
|
-
list-directories
|
|
103
|
+
list-directories List directories, including the default directory
|
|
106
104
|
|
|
107
|
-
set-shell-commands
|
|
105
|
+
set-shell-commands Set the Git, build, install and publish shell commands
|
|
108
106
|
|
|
109
|
-
add-ignored-dependency
|
|
107
|
+
add-ignored-dependency Add an ignored dependency
|
|
110
108
|
|
|
111
|
-
list-ignored-dependencies
|
|
109
|
+
list-ignored-dependencies List the ignored dependencies
|
|
112
110
|
|
|
113
|
-
remove-ignored-dependency
|
|
111
|
+
remove-ignored-dependency Remove an ignored dependency
|
|
114
112
|
|
|
115
|
-
add-forced-dependency-relation
|
|
113
|
+
add-forced-dependency-relation Add a forced dependency relation
|
|
116
114
|
|
|
117
|
-
list-forced-dependency-relations
|
|
115
|
+
list-forced-dependency-relations List the forced dependency relations
|
|
118
116
|
|
|
119
|
-
remove-forced-dependency-relation
|
|
117
|
+
remove-forced-dependency-relation Remove a forced dependency relation
|
|
120
118
|
|
|
121
119
|
Options:
|
|
122
120
|
|
|
123
|
-
--version|-v
|
|
121
|
+
--version|-v Show the version
|
|
124
122
|
|
|
125
|
-
--dry-run|-d
|
|
123
|
+
--dry-run|-d Show updates but do not apply them
|
|
126
124
|
|
|
127
|
-
--quietly|-q
|
|
125
|
+
--quietly|-q Execute shell commands without printing to the console
|
|
128
126
|
|
|
129
|
-
--yes|-y
|
|
127
|
+
--yes|-y Initially answer yes to prompts
|
|
130
128
|
|
|
131
|
-
--help|-h
|
|
129
|
+
--help|-h Show this help
|
|
132
130
|
```
|
|
133
131
|
|
|
134
132
|
In the directory that contains the sub-directories holding your project's packages and binaries, run the following command:
|
package/bin/action/help.js
CHANGED
|
@@ -3,53 +3,51 @@
|
|
|
3
3
|
function helpAction() {
|
|
4
4
|
console.log(`Usage:
|
|
5
5
|
|
|
6
|
-
propagate
|
|
6
|
+
propagate [<options>] Propagate the current package
|
|
7
7
|
|
|
8
|
-
propagate <sub-directory>
|
|
9
|
-
|
|
10
|
-
propagate <command>
|
|
8
|
+
propagate [<options>] <sub-directory> Propagate a package in the given sub-directory
|
|
11
9
|
|
|
12
10
|
propagate [<command>] [<options>]
|
|
13
11
|
|
|
14
12
|
Commands:
|
|
15
13
|
|
|
16
|
-
version
|
|
14
|
+
version Show the version
|
|
17
15
|
|
|
18
|
-
help
|
|
16
|
+
help Show this help
|
|
19
17
|
|
|
20
|
-
initialise
|
|
18
|
+
initialise Create a configuration file
|
|
21
19
|
|
|
22
|
-
add-directory
|
|
20
|
+
add-directory Add an additional directory
|
|
23
21
|
|
|
24
|
-
remove-directory
|
|
22
|
+
remove-directory Remove an additional directory
|
|
25
23
|
|
|
26
|
-
list-directories
|
|
24
|
+
list-directories List directories, including the default directory
|
|
27
25
|
|
|
28
|
-
set-shell-commands
|
|
26
|
+
set-shell-commands Set the Git, build, install and publish shell commands
|
|
29
27
|
|
|
30
|
-
add-ignored-dependency
|
|
28
|
+
add-ignored-dependency Add an ignored dependency
|
|
31
29
|
|
|
32
|
-
list-ignored-dependencies
|
|
30
|
+
list-ignored-dependencies List the ignored dependencies
|
|
33
31
|
|
|
34
|
-
remove-ignored-dependency
|
|
32
|
+
remove-ignored-dependency Remove an ignored dependency
|
|
35
33
|
|
|
36
|
-
add-forced-dependency-relation
|
|
34
|
+
add-forced-dependency-relation Add a forced dependency relation
|
|
37
35
|
|
|
38
|
-
list-forced-dependency-relations
|
|
36
|
+
list-forced-dependency-relations List the forced dependency relations
|
|
39
37
|
|
|
40
|
-
remove-forced-dependency-relation
|
|
38
|
+
remove-forced-dependency-relation Remove a forced dependency relation
|
|
41
39
|
|
|
42
40
|
Options:
|
|
43
41
|
|
|
44
|
-
--version|-v
|
|
42
|
+
--version|-v Show the version
|
|
45
43
|
|
|
46
|
-
--dry-run|-d
|
|
44
|
+
--dry-run|-d Show updates but do not apply them
|
|
47
45
|
|
|
48
|
-
--quietly|-q
|
|
46
|
+
--quietly|-q Execute shell commands without printing to the console
|
|
49
47
|
|
|
50
|
-
--yes|-y
|
|
48
|
+
--yes|-y Initially answer yes to prompts
|
|
51
49
|
|
|
52
|
-
--help|-h
|
|
50
|
+
--help|-h Show this help
|
|
53
51
|
|
|
54
52
|
Further information:
|
|
55
53
|
|
package/bin/main.js
CHANGED
|
@@ -5,31 +5,33 @@ const { pathUtilities } = require("necessary");
|
|
|
5
5
|
const actions = require("./actions");
|
|
6
6
|
|
|
7
7
|
const { TWO_DOTS } = require("./constants"),
|
|
8
|
-
{ PROPAGATE_COMMAND } = require("./commands")
|
|
8
|
+
{ PROPAGATE_COMMAND } = require("./commands");
|
|
9
|
+
const { DEFAULT_HELP, DEFAULT_VERSION } = require("./defaults"),
|
|
9
10
|
{ checkConfigurationFileExists, migrateConfigurationFile } = require("./configuration");
|
|
10
11
|
|
|
11
12
|
const { bottommostNameFromPath } = pathUtilities;
|
|
12
13
|
|
|
13
14
|
function main(command, argument, options) {
|
|
15
|
+
const commandExists = (command !== null),
|
|
16
|
+
{ help = DEFAULT_HELP, version = DEFAULT_VERSION } = options;
|
|
17
|
+
|
|
14
18
|
let configurationFileExists = checkConfigurationFileExists();
|
|
15
19
|
|
|
16
|
-
if (
|
|
17
|
-
|
|
18
|
-
const currentWorkingDirectoryPath = process.cwd(); ///
|
|
20
|
+
if (!help && !version && !commandExists && !configurationFileExists) { ///
|
|
21
|
+
const currentWorkingDirectoryPath = process.cwd(); ///
|
|
19
22
|
|
|
20
|
-
|
|
23
|
+
process.chdir(TWO_DOTS);
|
|
21
24
|
|
|
22
|
-
|
|
25
|
+
const oldCurrentWorkingDirectoryPath = currentWorkingDirectoryPath; ///
|
|
23
26
|
|
|
24
|
-
|
|
27
|
+
configurationFileExists = checkConfigurationFileExists();
|
|
25
28
|
|
|
26
|
-
|
|
27
|
-
|
|
29
|
+
if (configurationFileExists) {
|
|
30
|
+
const bottommostOldCurrentWorkingDirectoryName = bottommostNameFromPath(oldCurrentWorkingDirectoryPath);
|
|
28
31
|
|
|
29
|
-
|
|
32
|
+
command = PROPAGATE_COMMAND; ///
|
|
30
33
|
|
|
31
|
-
|
|
32
|
-
}
|
|
34
|
+
argument = bottommostOldCurrentWorkingDirectoryName; ///
|
|
33
35
|
}
|
|
34
36
|
}
|
|
35
37
|
|
package/package.json
CHANGED