Skip to content

Commit

Permalink
Remove all old references to the toolbox (#804)
Browse files Browse the repository at this point in the history
  • Loading branch information
0xTim committed Apr 28, 2023
1 parent 22724ab commit 0d669a7
Show file tree
Hide file tree
Showing 26 changed files with 74 additions and 74 deletions.
10 changes: 5 additions & 5 deletions docs/advanced/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ Vapor's Command API allows you to build custom command-line functions and intera
You can learn more about Vapor's default commands using the `--help` option.

```sh
vapor run --help
swift run App --help
```

You can use `--help` on a specific command to see what arguments and options it accepts.

```sh
vapor run serve --help
swift run App serve --help
```

### Xcode
Expand All @@ -38,7 +38,7 @@ struct HelloCommand: Command {
}
```

Adding the custom command to `app.commands` will make it available via `vapor run`.
Adding the custom command to `app.commands` will make it available via `swift run`.

```swift
app.commands.use(HelloCommand(), as: "hello")
Expand Down Expand Up @@ -74,7 +74,7 @@ context.console.print("Hello, \(name) 👋")
Test your command by running:

```sh
vapor run hello
swift run App hello
```

### Cowsay
Expand Down Expand Up @@ -125,5 +125,5 @@ app.commands.use(Cowsay(), as: "cowsay")
```

```sh
vapor run cowsay sup --eyes ^^ --tongue "U "
swift run App cowsay sup --eyes ^^ --tongue "U "
```
10 changes: 5 additions & 5 deletions docs/advanced/commands.nl.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ Vapor's Command API staat u toe om aangepaste command-line functies te bouwen en
U kunt meer te weten komen over de standaard commando's van Vapor door de `--help` optie te gebruiken.

```sh
vapor run --help
swift run App --help
```

Je kunt `--help` gebruiken voor een specifiek commando om te zien welke argumenten en opties het accepteert.

```sh
vapor run serve --help
swift run App serve --help
```

### Xcode
Expand All @@ -38,7 +38,7 @@ struct HelloCommand: Command {
}
```

Het toevoegen van het aangepaste commando aan `app.commands` maakt het beschikbaar via `vapor run`.
Het toevoegen van het aangepaste commando aan `app.commands` maakt het beschikbaar via `swift run`.

```swift
app.commands.use(HelloCommand(), as: "hello")
Expand Down Expand Up @@ -74,7 +74,7 @@ context.console.print("Hello, \(name) 👋")
Test je commando door het volgende uit te voeren:

```sh
vapor run hello
swift run App hello
```

### Cowsay
Expand Down Expand Up @@ -125,5 +125,5 @@ app.commands.use(Cowsay(), as: "cowsay")
```

```sh
vapor run cowsay sup --eyes ^^ --tongue "U "
swift run App cowsay sup --eyes ^^ --tongue "U "
```
10 changes: 5 additions & 5 deletions docs/advanced/commands.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ Vapor 的 Command API 允许你打造自定义命令行函数并且与终端进
通过 `--help` 选项你可以了解更多 Vapor 的默认指令。

```sh
vapor run --help
swift run App --help
```

你同样可以使用 `--help` 在特定的指令上以查看这个指令接受的参数和选项。

```sh
vapor run serve --help
swift run App serve --help
```

### Xcode
Expand All @@ -38,7 +38,7 @@ struct HelloCommand: Command {
}
```

将自定义指令加入到 `app.commands` 将允许你使用这个指令通过 `vapor run`
将自定义指令加入到 `app.commands` 将允许你使用这个指令通过 `swift run`

```swift
app.commands.use(HelloCommand(), as: "hello")
Expand Down Expand Up @@ -74,7 +74,7 @@ context.console.print("Hello, \(name) 👋")
通过运行你的命令来测试:

```sh
vapor run hello
swift run App hello
```

### Cowsay
Expand Down Expand Up @@ -125,5 +125,5 @@ app.commands.use(Cowsay(), as: "cowsay")
```

```sh
vapor run cowsay sup --eyes ^^ --tongue "U "
swift run App cowsay sup --eyes ^^ --tongue "U "
```
2 changes: 1 addition & 1 deletion docs/advanced/queues.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ app.queues.add(emailJob)

### Running Workers as Processes

To start a new queue worker, run `vapor run queues`. You can also specify a specific type of worker to run: `vapor run queues --queue emails`.
To start a new queue worker, run `swift run App queues`. You can also specify a specific type of worker to run: `swift run App queues --queue emails`.

!!! tip
Workers should stay running in production. Consult your hosting provider to find out how to keep long-running processes alive. Heroku, for example, allows you to specify "worker" dynos like this in your Procfile: `worker: Run queues`. With this in place, you can start workers on the Dashboard/Resources tab, or with `heroku ps:scale worker=1` (or any number of dynos preferred).
Expand Down
2 changes: 1 addition & 1 deletion docs/advanced/queues.nl.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ app.queues.add(emailJob)

### Workers Uitvoeren Als Processen

Om een nieuwe wachtrijwerker te starten, voer `vapor run queues` uit. U kunt ook een specifiek type werker specificeren om te draaien: `vapor run queues --queue emails`.
Om een nieuwe wachtrijwerker te starten, voer `swift run App queues` uit. U kunt ook een specifiek type werker specificeren om te draaien: `swift run App queues --queue emails`.

!!! tip
Workers moeten blijven draaien in productie. Raadpleeg uw hosting provider om uit te vinden hoe u langlopende processen in leven kunt houden. Heroku, bijvoorbeeld, staat je toe om "worker" dyno's te specificeren zoals dit in je Procfile: `worker: Run queues`. Met dit in plaats, kun je workers starten op het Dashboard/Resources tab, of met `heroku ps:scale worker=1` (of elk gewenst aantal dynos).
Expand Down
2 changes: 1 addition & 1 deletion docs/advanced/queues.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ app.queues.add(emailJob)

### Worker 作为进程运行

要启动新的队列 worker,请在终端运行 `vapor run queues`。 你还可以指定一个特定类型的 worker 来运行 `vapor run queues --queue emails`
要启动新的队列 worker,请在终端运行 `swift run App queues`。 你还可以指定一个特定类型的 worker 来运行 `swift run App queues --queue emails`

!!! tip "建议"
生产环境应该保持 worker 一直运行。咨询你的托管提供商,了解如何保持长时间运行的进程处于活动状态。例如,Heroku 允许你在 Procfile 中指定这样的 “worker” dynos:`worker: Run queues`。有了这个,你可以在仪表板/资源选项卡上启动 worker,或者使用 `heroku ps:scale worker=1`(或首选的任何数量的 dynos)。
Expand Down
10 changes: 5 additions & 5 deletions docs/advanced/server.de.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,17 +177,17 @@ try app.server.onShutdown.wait()
Um den Server zu starten, kannst du Terminal-Befehl _serve_ verwenden. Der Befehl wird automatisch ausgeführt, wenn keine anderen Befehle mitangegeben werden.

```swift
vapor run serve
swift run App serve
```

Es können folgende Parameter mitangegeben werden:

| Name | Befehl | Beschreibung | Beispiel |
|-----------------------|----------------|------------------------------------------------------|-------------------------------|
| hostname | -H | Überschreibt den vordefinierten Hostname | vapor run serve -H dev.local |
| port | -p | Überschreibt den vordefinierten Port | vapor run serve -p 1337 |
| bind | -b | Überschreibt den vordefinierten Hostnamen und Port | vapor run serve -b 0.0.0.0:80 |
| help | --help | Hilfe | vapor run serve --help |
| hostname | -H | Überschreibt den vordefinierten Hostname | swift run App serve -H dev.local |
| port | -p | Überschreibt den vordefinierten Port | swift run App serve -p 1337 |
| bind | -b | Überschreibt den vordefinierten Hostnamen und Port | swift run App serve -b 0.0.0.0:80 |
| help | --help | Hilfe | swift run App serve --help |

## Hinweis

Expand Down
10 changes: 5 additions & 5 deletions docs/advanced/server.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ The server configuration's hostname can be overridden by passing the `--hostname

```sh
# Override configured hostname.
vapor run serve --hostname dev.local
swift run App serve --hostname dev.local
```

### Port
Expand All @@ -46,7 +46,7 @@ The server configuration's port can be overridden by passing the `--port` (`-p`)

```sh
# Override configured port.
vapor run serve --port 1337
swift run App serve --port 1337
```

### Backlog
Expand Down Expand Up @@ -161,7 +161,7 @@ app.http.server.configuration.serverName = "vapor"
To start up Vapor's server, use the `serve` command. This command will run by default if no other commands are specified.

```swift
vapor run serve
swift run App serve
```

The `serve` command accepts the following parameters:
Expand All @@ -173,10 +173,10 @@ The `serve` command accepts the following parameters:
An example using the `--bind` (`-b`) flag:

```swift
vapor run serve -b 0.0.0.0:80
swift run App serve -b 0.0.0.0:80
```

Use `vapor run serve --help` for more information.
Use `swift run App serve --help` for more information.

The `serve` command will listen for `SIGTERM` and `SIGINT` to gracefully shutdown the server. Use `ctrl+c` (`^c`) to send a `SIGINT` signal. When the log level is set to `debug` or lower, information about the status of graceful shutdown will be logged.

Expand Down
10 changes: 5 additions & 5 deletions docs/advanced/server.nl.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ De hostnaam van de serverconfiguratie kan worden veranderd door de `--hostname`

```sh
# Overschrijf geconfigureerde hostnaam.
vapor run serve --hostname dev.local
swift run App serve --hostname dev.local
```

### Poort
Expand All @@ -46,7 +46,7 @@ De poort van de server configuratie kan overschreven worden door de `--port` (`-

```sh
# Overschrijf geconfigureerde poort.
vapor run serve --port 1337
swift run App serve --port 1337
```

### Backlog
Expand Down Expand Up @@ -161,7 +161,7 @@ app.http.server.configuration.serverName = "vapor"
Om de server van Vapor op te starten, gebruik het `serve` commando. Dit commando wordt standaard uitgevoerd als er geen andere commando's zijn opgegeven.

```swift
vapor run serve
swift run App serve
```

Het `serve` commando accepteert de volgende parameters:
Expand All @@ -173,10 +173,10 @@ Het `serve` commando accepteert de volgende parameters:
Een voorbeeld met de `--bind` (`-b`) vlag:

```swift
vapor run serve -b 0.0.0.0:80
swift run App serve -b 0.0.0.0:80
```

Gebruik `vapor run serve --help` voor meer informatie.
Gebruik `swift run App serve --help` voor meer informatie.

Het `serve` commando zal luisteren naar `SIGTERM` en `SIGINT` om de server netjes af te sluiten. Gebruik `ctrl+c` (`^c`) om een `SIGINT` signaal te sturen. Als het log level is ingesteld op `debug` of lager, zal informatie over de status van graceful shutdown worden gelogd.

Expand Down
10 changes: 5 additions & 5 deletions docs/advanced/server.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ app.http.server.configuration.hostname = "dev.local"

```sh
# 重写主机名配置
vapor run serve --hostname dev.local
swift run App serve --hostname dev.local
```

### 端口
Expand All @@ -45,7 +45,7 @@ app.http.server.configuration.port = 1337

```sh
# 重写端口配置
vapor run serve --port 1337
swift run App serve --port 1337
```

### Backlog
Expand Down Expand Up @@ -160,7 +160,7 @@ app.http.server.configuration.serverName = "vapor"
要启动 Vapor 的服务器,请在终端使用 `serve` 命令。如果没有指定其他命令,该命令将默认运行。

```swift
vapor run serve
swift run App serve
```

`serve` 命令接受以下参数:
Expand All @@ -172,10 +172,10 @@ vapor run serve
下面是使用 `--bind` (`-b`) 标志的一个示例:

```swift
vapor run serve -b 0.0.0.0:80
swift run App serve -b 0.0.0.0:80
```

使用 `vapor run serve --help` 以获取更多信息。
使用 `swift run App serve --help` 以获取更多信息。

`serve` 命令将侦听 `SIGTERM``SIGINT` 信号,以正常关闭服务器。使用 `ctrl+c` (`^c`) 发送 `SIGINT` 信号。当日志级别设置为 `debug` 或更低时,将记录有关安全关机状态的信息。

Expand Down
4 changes: 2 additions & 2 deletions docs/basics/environment.de.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ default:
## Wechsel

```swift
vapor run serve --env production
swift run App serve --env production
```

## Umgebungsvariable
Expand Down Expand Up @@ -58,7 +58,7 @@ Im Terminal gibt es hierzu den Befehl _export_:

```sh
export FOO=BAR
vapor run serve
swift run App serve
```

### Umgebungsdatei
Expand Down
6 changes: 3 additions & 3 deletions docs/basics/environment.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ default:
By default, your app will run in the `development` environment. You can change this by passing the `--env` (`-e`) flag during app boot.

```swift
vapor run serve --env production
swift run App serve --env production
```

Vapor includes the following environments:
Expand All @@ -35,7 +35,7 @@ Vapor includes the following environments:
You can pass either the full or short name to the `--env` (`-e`) flag.

```swift
vapor run serve -e prod
swift run App serve -e prod
```

## Process Variables
Expand All @@ -58,7 +58,7 @@ When running your app in the terminal, you can set environment variables using `

```sh
export FOO=BAR
vapor run serve
swift run App serve
```

When running your app in Xcode, you can set environment variables by editing the `App` scheme.
Expand Down
6 changes: 3 additions & 3 deletions docs/basics/environment.nl.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ default:
Standaard zal uw app in de `development` omgeving draaien. U kunt dit veranderen door de `--env` (`-e`) vlag mee te geven tijdens het opstarten van de app.

```swift
vapor run serve --env production
swift run App serve --env production
```

Vapor omvat de volgende omgevingen:
Expand All @@ -35,7 +35,7 @@ Vapor omvat de volgende omgevingen:
Je kunt de volledige of korte naam doorgeven aan de `--env` (`-e`) vlag.

```swift
vapor run serve -e prod
swift run App serve -e prod
```

## Procesvariabelen
Expand All @@ -58,7 +58,7 @@ Wanneer u uw app in de terminal draait, kunt u omgevingsvariabelen instellen met

```sh
export FOO=BAR
vapor run serve
swift run App serve
```

Wanneer u uw app in Xcode uitvoert, kunt u omgevingsvariabelen instellen door het `App` schema te bewerken.
Expand Down
6 changes: 3 additions & 3 deletions docs/basics/environment.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ default:
默认情况下,你的应用程序将在 `development` 环境中运行。你可以通过在应用程序引导期间传递 `--env` (`-e`) 标志来改变这一点。

```swift
vapor run serve --env production
swift run App serve --env production
```

Vapor 包含下列环境:
Expand All @@ -35,7 +35,7 @@ Vapor 包含下列环境:
你可以将全名或短名传递给`--env` (`-e`) 标志。

```swift
vapor run serve -e prod
swift run App serve -e prod
```

## 进程变量
Expand All @@ -58,7 +58,7 @@ print(foo) // String?

```sh
export FOO=BAR
vapor run serve
swift run App serve
```

当在 Xcode 中运行应用程序时,你可以通过编辑 `App` scheme 来设置环境变量。
Expand Down
Loading

0 comments on commit 0d669a7

Please sign in to comment.