Skip to content

Commit 2e43881

Browse files
committed
Remove line breaks from long WinGet command
The WinGet command for installing Windows platform dependencies contained line breaks. When copied, the line breaks would break the command up in to multiple lines. The first line is a valid command and so runs sucessfully but the subsequent lines are truncated and will produce an error if run. Update the command to remove line breaks, and update the css for `.code-box pre code`` to add back in line breaks in css that are not preserved when the command is copied. The swiftly install command breaks the command up with backslashes `\` but on Windows we would have to either use `^` for cmd.exe or backtick for powershell. This ambiguity means its safer just to put the whole command on one line.
1 parent e9b15b9 commit 2e43881

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

_data/new-data/install/windows/releases.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,7 @@ latest-release:
55
headline: WinGet
66
after-code-text: |
77
First, install Windows platform dependencies:
8-
<pre><code>winget install --id Microsoft.VisualStudio.2022.Community --exact --force
9-
--custom "--add Microsoft.VisualStudio.Component.Windows11SDK.22000 --add
10-
Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add
11-
Microsoft.VisualStudio.Component.VC.Tools.ARM64"</code></pre>
8+
<pre><code>winget install --id Microsoft.VisualStudio.2022.Community --exact --force --custom "--add Microsoft.VisualStudio.Component.Windows11SDK.22000 --add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 --add Microsoft.VisualStudio.Component.VC.Tools.ARM64"</code></pre>
129
<br />
1310
Next, install Swift and other dependencies:
1411
<br /><br />

assets/stylesheets/new-stylesheets/pages/_get-started.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -434,6 +434,10 @@
434434
pre {
435435
max-height: 400px;
436436
border: var(--get-started-code-box-pre-border);
437+
438+
code {
439+
white-space: pre-wrap;
440+
}
437441
}
438442

439443
&.code-box-with-tabs {

0 commit comments

Comments
 (0)