-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix a few syntax issues in shell scripts #62102
Conversation
I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label. |
9520955
to
ab8553c
Compare
```sh # git remote add dotnet https://github.com/dotnet/runtime && git pull --rebase dotnet main if uname 2>/devnull | grep -q Darwin; then space=" " fi git show --name-only --pretty="" HEAD...dotnet/main |\ xargs -I{} sh -c "test -f {} && sed -i$space'' 's/[[:space:]]*$//' {}" ```
ab8553c
to
17c6508
Compare
src/libraries/System.Net.Http/tests/StressTests/HttpStress/run-docker-compose.sh
Show resolved
Hide resolved
Tagging subscribers to this area: @dotnet/runtime-infrastructure Issue DetailsThis delta updates shell scripts for consistency. In particular, avoid mixing Bash and Unix shell syntax by replacing:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a couple minor questions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thanks!
@radical could you please look at the staging failure? |
This change broke the (non-mandatory) SslStress pipeline. When touching
|
This delta updates shell scripts for consistency. In particular, avoid mixing Bash and Unix shell syntax by replacing:
[ $x == $y ]
and[[ $x = $y ]]
with[[ $x == $y ]]
[[ $x ]] && [[ $y ]]
and[ $x ] && [ $y ]
with[[ $x && $y ]]
[ ! -z $x ]
and[ $x != "" ]
with[ -n $x ]
[ ! -n $x ]
and[ $x == "" ]
with[ -z $x ]
! $x == $y
with$x != $y
#!/bin/bash
with#!/usr/bin/env bash
[[
with[
in files with/bin/sh
shebang