Skip to content

Commit

Permalink
Bump version 2.0.2
Browse files Browse the repository at this point in the history
  • Loading branch information
swiftyfinch committed Aug 6, 2023
1 parent 207c4c3 commit 617e54d
Show file tree
Hide file tree
Showing 9 changed files with 205 additions and 31 deletions.
2 changes: 1 addition & 1 deletion Sources/Rugby/Rugby.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ struct Rugby: AsyncParsableCommand {
static var configuration = CommandConfiguration(
// Use someting from Foundation for excluding Linux from Swift Package Index.
// Rugby doesn't support this platform.
version: NSString(string: "2.0.1").description
version: NSString(string: "2.0.2").description
)
}
168 changes: 161 additions & 7 deletions docs/commands-help/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,17 @@
Subcommands:
╭──────────────────────────────────────────────────────────────────────╮
│ shortcuts * Set of base commands combinations. │
│ warmup * Download remote binaries for targets from Pods project. │
│ build * Build targets from Pods project. │
│ use * Use already built binaries instead of sources. │
│ delete * Delete targets from the project. │
plan * Run sequence of Rugby commands.
warmup * Download remote binaries for targets from Pods project.
│ rollback * Restore projects state before the last Rugby usage. │
│ plan * Run sequence of Rugby commands. │
│ clear * Clear modules cache. │
│ update * Update Rugby version. │
│ doctor * Heal your wounds after using Rugby (or not). │
│ shell * Run shell command from Rugby. │
│ env * Print Rugby environment. │
╰──────────────────────────────────────────────────────────────────────╯
Flags:
╭──────────────────────────────────────╮
Expand All @@ -28,8 +29,161 @@
╰──────────────────────────────────────╯
```

| Mixed | Basic | Advanced | Utils | Misc |
| :---: | :---: | :---: | :---: | :---: |
| 📍 [Shortcuts](shortcuts.md) | 🏗️ [Build](build.md) | 🐳 [Warmup](warmup.md) | ♻️ [Rollback](rollback.md) | 📦 [Update](update.md) |
| ✈️ [Plan](plan.md) | 🎯 [Use](use.md) | 🗑️ [Delete](delete.md) | 🧼 [Clear](clear.md) | 🚑 [Doctor](doctor.md) |
| | | | 🐚 [Shell](shell.md) | |
| [Basic](#basic) | [Mixed](#mixed) | [Utils](#utils) |
| :---: | :---: | :---: |
| 🏗️ [Build](build.md) | 📍 [Shortcuts](shortcuts.md) | 🧼 [Clear](clear.md) |
| 🎯 [Use](use.md) | ⛱️ [Umbrella](shortcuts/umbrella.md) | 📦 [Update](update.md) |
| 🗑️ [Delete](delete.md) | 🏈 [Cache](shortcuts/cache.md) | 🚑 [Doctor](doctor.md) |
| 🐳 [Warmup](warmup.md) | ✈️ [Plan](plan.md) | 🐚 [Shell](shell.md) |
| ♻️ [Rollback](rollback.md) | | 🌍 [Env](env.md) |

## Basic

```mermaid
flowchart LR
S((("Rugby")))
S --> A("Basic")
A --> AA(["🏗️ Build"]) -.-> AAA["
Build targets from Pods project
"]
style AA color:#539bf5
click AA "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/build.md" _blank
A --> AB(["🎯 Use"]) -.-> ABA["
Use already built binaries
instead of sources
"]
style AB color:#539bf5
click AB "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/use.md" _blank
A --> AC(["🗑️ Delete"]) -.-> ACA["
Delete targets from the project
"]
style AC color:#539bf5
click AC "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/delete.md" _blank
A --> AD(["🐳 Warmup"]) -.-> ADA["
Download remote binaries
for targets from Pods project
"]
style AD color:#539bf5
click AD "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/warmup.md" _blank
A --> AE(["♻️ Rollback"]) -.-> AEA["
Restore projects state
before the last Rugby usage
"]
style AE color:#539bf5
click AE "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/rollback.md" _blank
```

## Mixed

```mermaid
flowchart LR
A((("Rugby")))
A --> B("
📍 Shortcuts
(default)
")
B --> BA("🏈 Cache")
BA --> BAA("
♻️ Rollback
🐳 Warmup
🏗️ Build
🎯 Use
")
B --> BB("
⛱️ Umbrella
(default)
")
BB --> BA
BB --> D
A --> D("✈️ Plan")
D --> DA("
Any combination
of commands
")
A --> F("🏗️ Build")
A --> G("🎯 Use")
A --> H("🗑️ Delete")
A --> E("🐳 Warmup")
A --> J("♻️ Rollback")
click B "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/shortcuts.md" _blank
```

```mermaid
flowchart TD
S((("Rugby")))
S --> A("Mixed")
A --> AA["
📍 Shortcuts (default)<hr>Set of base commands
combinations
"]
style AA color:#539bf5
click AA "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/shortcuts.md" _blank
AA --> AAB["
🏈 Cache<hr>Run the build and use commands
"]
style AAB color:#539bf5
click AAB "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/shortcuts/cache.md" _blank
AA --> AAA["
⛱️ Umbrella (default)<hr>Run the plan command
if plans file exists or
run the cache command
"]
style AAA color:#539bf5
click AAA "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/shortcuts/umbrella.md" _blank
AAA --> AAB
AAA --> AB
A --> AB["
✈️ Plan<hr>Run sequence of Rugby commands
"]
style AB color:#539bf5
click AB "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/plan.md" _blank
```

## Utils

```mermaid
flowchart LR
S((("Rugby")))
S --> A("Utils")
A --> AA(["🧼 Clear"]) -.-> AAA["
Clear modules cache
"]
style AA color:#539bf5
click AA "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/clear.md" _blank
A --> AB(["📦 Update"]) -.-> ABA["
Update Rugby version
"]
style AB color:#539bf5
click AB "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/update.md" _blank
A --> AC(["🚑 Doctor"]) -.-> ACA["
Heal your wounds
after using Rugby (or not)
"]
style AC color:#539bf5
click AC "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/doctor.md" _blank
A --> AE(["🐚 Shell"]) -.-> AEA["
Run shell command from Rugby
"]
style AE color:#539bf5
click AE "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/shell.md" _blank
A --> AF(["🌍 Env"]) -.-> AFA["
Print Rugby environment
"]
style AF color:#539bf5
click AF "https://github.com/swiftyfinch/Rugby/blob/main/docs/commands-help/env.md" _blank
```
2 changes: 1 addition & 1 deletion docs/commands-help/build.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
│ -a, --arch * Build architecture: auto, x86_64 or arm64. │
│ -c, --config * Build configuration. (Debug) │
│ -t, --targets [] * Targets for building. Empty means all targets. │
│ -r, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -g, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -e, --except [] * Exclude targets from building. │
│ -x, --except-as-regex [] * Exclude targets from building as a RegEx pattern. │
│ -o, --output * Output mode: fold, multiline, quiet. │
Expand Down
2 changes: 1 addition & 1 deletion docs/commands-help/delete.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
╭────────────────────────────────────────────────────────────────────────────────╮
│ -p, --path * Project location. (Pods/Pods.xcodeproj) │
│ -t, --targets [] * Targets for building. Empty means all targets. │
│ -r, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -g, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -e, --except [] * Exclude targets from building. │
│ -x, --except-as-regex [] * Exclude targets from building as a RegEx pattern. │
│ -o, --output * Output mode: fold, multiline, quiet. │
Expand Down
17 changes: 17 additions & 0 deletions docs/commands-help/env.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[< 📚 Commands Help](README.md)

# 🌍 Env

```sh
> rugby env --help
```

```sh

> Print Rugby environment.

Flags:
╭──────────────────────────────────────╮
│ -h, --help * Show help information. │
╰──────────────────────────────────────╯
```
15 changes: 8 additions & 7 deletions docs/commands-help/plan.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@
│ -o, --output * Output mode: fold, multiline, quiet. │
╰────────────────────────────────────────────────────────╯
Flags:
╭────────────────────────────────────────────╮
│ -v, --verbose [] * Log level. │
│ -h, --help * Show help information. │
╰────────────────────────────────────────────╯
╭─────────────────────────────────────────────────────────────────────────╮
│ -r, --rollback * Restore projects state before the last Rugby usage. │
│ -v, --verbose [] * Log level. │
│ -h, --help * Show help information. │
╰─────────────────────────────────────────────────────────────────────────╯
```

# Discussion
Expand All @@ -44,9 +45,9 @@ cache_plan_name:
It's equal to this sequence of commands:
```sh
> warmup s3.eu-west-2.amazonaws.com --except SomePod --arch x86_64
> build --except SomePod --arch x86_64
> use --except SomePod
> rugby warmup s3.eu-west-2.amazonaws.com --except SomePod --arch x86_64
> rugby build --except SomePod --arch x86_64
> rugby use --except SomePod
```

Then you need to save YAML to `.rugby/plans.yml` file or in another place.\
Expand Down
26 changes: 14 additions & 12 deletions docs/commands-help/shortcuts/cache.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,34 +16,36 @@
│ -a, --arch * Build architecture: auto, x86_64 or arm64. │
│ -c, --config * Build configuration. (Debug) │
│ -t, --targets [] * Targets for building. Empty means all targets. │
│ -r, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -g, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -e, --except [] * Exclude targets from building. │
│ -x, --except-as-regex [] * Exclude targets from building as a RegEx pattern. │
│ -o, --output * Output mode: fold, multiline, quiet. │
│ --warmup * Warmup cache with this endpoint. │
╰────────────────────────────────────────────────────────────────────────────────╯
Flags:
╭────────────────────────────────────────────────────────╮
│ --ignore-cache * Ignore shared cache. │
│ --delete-sources * Delete target groups from project. │
│ --strip * Build without debug symbols. │
│ -v, --verbose [] * Log level. │
│ -h, --help * Show help information. │
╰────────────────────────────────────────────────────────╯
╭─────────────────────────────────────────────────────────────────────────╮
│ --ignore-cache * Ignore shared cache. │
│ --delete-sources * Delete target groups from project. │
│ -r, --rollback * Restore projects state before the last Rugby usage. │
│ --strip * Build without debug symbols. │
│ -v, --verbose [] * Log level. │
│ -h, --help * Show help information. │
╰─────────────────────────────────────────────────────────────────────────╯
```

## Discussion

It just a combination of exist commands. You can call them separately:
```sh
> warmup s3.eu-west-2.amazonaws.com --except SomePod --arch x86_64
> build --except SomePod --arch x86_64
> use --except SomePod
> rugby rollback
> rugby warmup s3.eu-west-2.amazonaws.com --except SomePod --arch x86_64
> rugby build --except SomePod --arch x86_64
> rugby use --except SomePod
```

Or just use cache shortcut:
```sh
> cache --warmup s3.eu-west-2.amazonaws.com --except SomePod --arch x86_64
> rugby cache --rollback --warmup s3.eu-west-2.amazonaws.com --except SomePod --arch x86_64
```

When you use cache or [plan](../plan.md) commands Rugby tries to reuse project cache.\
Expand Down
2 changes: 1 addition & 1 deletion docs/commands-help/use.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
Options:
╭────────────────────────────────────────────────────────────────────────────────╮
│ -t, --targets [] * Targets for building. Empty means all targets. │
│ -r, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -g, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -e, --except [] * Exclude targets from building. │
│ -x, --except-as-regex [] * Exclude targets from building as a RegEx pattern. │
│ -o, --output * Output mode: fold, multiline, quiet. │
Expand Down
2 changes: 1 addition & 1 deletion docs/commands-help/warmup.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
│ -a, --arch * Build architecture: auto, x86_64 or arm64. │
│ -c, --config * Build configuration. (Debug) │
│ -t, --targets [] * Targets for building. Empty means all targets. │
│ -r, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -g, --targets-as-regex [] * Targets for building as a RegEx pattern. │
│ -e, --except [] * Exclude targets from building. │
│ -x, --except-as-regex [] * Exclude targets from building as a RegEx pattern. │
│ -o, --output * Output mode: fold, multiline, quiet. │
Expand Down

0 comments on commit 617e54d

Please sign in to comment.