monorepo 0.2.0 → 0.2.1
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.
- checksums.yaml +5 -5
- data/README.md +48 -15
- data/RELEASE_NOTE.md +9 -0
- data/lib/commands/bootstrap.rb +1 -1
- data/lib/commands/exec.rb +1 -1
- data/lib/commands/init.rb +1 -1
- data/lib/commands/ls.rb +8 -1
- data/lib/commands/rake.rb +1 -1
- data/lib/commands/version.rb +1 -1
- data/lib/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
|
-
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
2
|
+
SHA1:
|
|
3
|
+
metadata.gz: 334e5e67426609fc762c2b86ae367065d3b3986b
|
|
4
|
+
data.tar.gz: 0aa5aa993684f7cb290b69e3ebe56a725788a6e8
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: c262a41c4276652c254abe74e0dc1733dcdaa0832c45bdf728f4d6d7d8768646f63954b6a58cb8a5111254a9d47b80761454afae4828d5371c1e844f11631037
|
|
7
|
+
data.tar.gz: 04a6a830527f8594c4065eaa4f7282ac0034d60999887afc7c5530e0168f7a501db4f654fca71cf88093635e281e2a7e5eb9b5ff0840a0c05656dbc5bde51d1a
|
data/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
[](https://badge.fury.io/rb/monorepo)
|
|
4
4
|
[](https://travis-ci.org/kamataryo/monorepo)
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
Ruby based simple monorepo management tool like [Lerna](https://lernajs.io/).
|
|
7
7
|
Monorepo is a single repository which hosts multiple libraries.
|
|
8
8
|
You can arrange and integrate lint, test, release and other workflows with monorepo.
|
|
9
9
|
[Babel](https://babeljs.io/), [ESLint](https://eslint.org/) and other projects likely has plugin ecosystem take monorepo strategy.
|
|
@@ -12,20 +12,37 @@ You can arrange and integrate lint, test, release and other workflows with monor
|
|
|
12
12
|
|
|
13
13
|
Install it yourself as:
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
```
|
|
16
|
+
$ gem install monorepo
|
|
17
|
+
```
|
|
16
18
|
|
|
17
|
-
##
|
|
19
|
+
## CLI reference
|
|
18
20
|
|
|
19
|
-
|
|
21
|
+
### `monorepo init`
|
|
20
22
|
|
|
21
|
-
Initialize
|
|
23
|
+
Initialize your project for `monorepo`.
|
|
22
24
|
|
|
23
25
|
```shell
|
|
26
|
+
$ mkdir project_name
|
|
27
|
+
$ cd project_name
|
|
24
28
|
$ monorepo init
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Or you can specify some options.
|
|
32
|
+
|
|
33
|
+
```shell
|
|
34
|
+
# Specify config file name
|
|
35
|
+
$ monorepo init --config_filename ./your_monorepo_config_file
|
|
36
|
+
$ monorepo init -c ./your_monorepo_config_file
|
|
37
|
+
|
|
38
|
+
# Specify gems directory name
|
|
39
|
+
$ monorepo init --gems specified_gem_dir
|
|
40
|
+
$ monorepo init -g specified_gem_dir
|
|
41
|
+
|
|
42
|
+
# Specify bundler option to use `bundle exec` or not.
|
|
43
|
+
# with `yes`, `y` or `true`, `bundle exec` are always attached with subcommand execution.
|
|
44
|
+
$ monorepo init -b YES
|
|
45
|
+
$ monorepo init --bundler YES
|
|
29
46
|
```
|
|
30
47
|
|
|
31
48
|
```shell
|
|
@@ -36,7 +53,7 @@ $ tree .
|
|
|
36
53
|
└── gems
|
|
37
54
|
```
|
|
38
55
|
|
|
39
|
-
You can add and arrange any numbers of child gems inside `./gems`
|
|
56
|
+
You can add and arrange any numbers of child gems inside `./gems` directory.
|
|
40
57
|
|
|
41
58
|
```shell
|
|
42
59
|
$ tree .
|
|
@@ -47,13 +64,12 @@ $ tree .
|
|
|
47
64
|
└── gem-b
|
|
48
65
|
```
|
|
49
66
|
|
|
50
|
-
|
|
67
|
+
### `monorepo exec`
|
|
51
68
|
|
|
52
69
|
Exec commands in each child gems.
|
|
53
70
|
|
|
54
71
|
```shell
|
|
55
72
|
$ monorepo exec [COMMAND]
|
|
56
|
-
$ monorepo exec [COMMAND] -c ./Monorepofile
|
|
57
73
|
```
|
|
58
74
|
|
|
59
75
|
An example:
|
|
@@ -70,13 +86,30 @@ $ tree .
|
|
|
70
86
|
└── Gemfile
|
|
71
87
|
```
|
|
72
88
|
|
|
73
|
-
|
|
89
|
+
```shell
|
|
90
|
+
# use bundler option
|
|
91
|
+
$ .monorepo exec -b ls
|
|
92
|
+
executing `bundle exec ls` at gems/gem-a...
|
|
93
|
+
/path/to/monorepo/root/gems/gem-a
|
|
94
|
+
Gemfile Gemfile.lock
|
|
95
|
+
executing `bundle exec ls` at gems/gem-b...
|
|
96
|
+
/path/to/monorepo/root/gems/gem-b
|
|
97
|
+
Gemfile Gemfile.lock
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
### `monorepo rake`
|
|
74
101
|
|
|
75
102
|
Run rake task in each child gems.
|
|
76
103
|
|
|
77
104
|
```shell
|
|
78
|
-
$ monorepo rake
|
|
79
|
-
$ monorepo rake [TASK]
|
|
105
|
+
$ monorepo rake # with default rake task
|
|
106
|
+
$ monorepo rake [TASK] # with specified rake task
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
## Usage
|
|
110
|
+
|
|
111
|
+
```
|
|
112
|
+
$ monorepo rake spec
|
|
80
113
|
```
|
|
81
114
|
|
|
82
115
|
## Development
|
data/RELEASE_NOTE.md
ADDED
data/lib/commands/bootstrap.rb
CHANGED
data/lib/commands/exec.rb
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
class MonorepoCLI
|
|
2
2
|
EXIT_STATUS_ZERO = 0
|
|
3
3
|
|
|
4
|
-
desc 'exec [COMMAND]', '
|
|
4
|
+
desc 'exec [COMMAND]', 'Execute a command for each child repository'
|
|
5
5
|
method_option :config_filename, aliases: '-c'
|
|
6
6
|
method_option :bundler, aliases: '-b'
|
|
7
7
|
|
data/lib/commands/init.rb
CHANGED
data/lib/commands/ls.rb
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
class MonorepoCLI
|
|
2
|
-
desc 'ls', '
|
|
2
|
+
desc 'ls', 'List all child repositories'
|
|
3
3
|
method_option :config_filename, aliases: '-c'
|
|
4
4
|
|
|
5
5
|
def ls
|
|
@@ -26,4 +26,11 @@ class MonorepoCLI
|
|
|
26
26
|
|
|
27
27
|
puts subdirs.join("\n")
|
|
28
28
|
end
|
|
29
|
+
|
|
30
|
+
desc 'list', 'List all child repositories'
|
|
31
|
+
method_option :config_filename, aliases: '-c'
|
|
32
|
+
|
|
33
|
+
def list
|
|
34
|
+
self.ls
|
|
35
|
+
end
|
|
29
36
|
end
|
data/lib/commands/rake.rb
CHANGED
data/lib/commands/version.rb
CHANGED
data/lib/version.rb
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
MONOREPO_VERSION = '0.2.
|
|
1
|
+
MONOREPO_VERSION = '0.2.1'.freeze
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: monorepo
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- kamataryo
|
|
@@ -98,6 +98,7 @@ files:
|
|
|
98
98
|
- Gemfile
|
|
99
99
|
- LICENSE.txt
|
|
100
100
|
- README.md
|
|
101
|
+
- RELEASE_NOTE.md
|
|
101
102
|
- Rakefile
|
|
102
103
|
- bin/console
|
|
103
104
|
- bin/setup
|
|
@@ -131,7 +132,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
131
132
|
version: '0'
|
|
132
133
|
requirements: []
|
|
133
134
|
rubyforge_project:
|
|
134
|
-
rubygems_version: 2.
|
|
135
|
+
rubygems_version: 2.6.11
|
|
135
136
|
signing_key:
|
|
136
137
|
specification_version: 4
|
|
137
138
|
summary: Monorepo management tool
|