Skip to content

chore(deps-dev): bump prettier-plugin-sh from 0.6.1 to 0.7.1 #3680

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

Merged
merged 2 commits into from
Jun 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ci/build/build-packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ release_gcp() {
# Generates deb and rpm packages.
release_nfpm() {
local nfpm_config
nfpm_config="$(envsubst <./ci/build/nfpm.yaml)"
nfpm_config="$(envsubst < ./ci/build/nfpm.yaml)"

# The underscores are convention for .deb.
nfpm pkg -f <(echo "$nfpm_config") --target "release-packages/code-server_${VERSION}_$ARCH.deb"
Expand Down
10 changes: 5 additions & 5 deletions ci/build/build-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,15 @@ bundle_code_server() {

# Adds the commit to package.json
jq --slurp '.[0] * .[1]' package.json <(
cat <<EOF
cat << EOF
{
"commit": "$(git rev-parse HEAD)",
"scripts": {
"postinstall": "./postinstall.sh"
}
}
EOF
) >"$RELEASE_PATH/package.json"
) > "$RELEASE_PATH/package.json"
rsync yarn.lock "$RELEASE_PATH"
rsync ci/build/npm-postinstall.sh "$RELEASE_PATH/postinstall.sh"

Expand Down Expand Up @@ -83,18 +83,18 @@ bundle_vscode() {

# Adds the commit and date to product.json
jq --slurp '.[0] * .[1]' "$VSCODE_SRC_PATH/product.json" <(
cat <<EOF
cat << EOF
{
"commit": "$(git rev-parse HEAD)",
"date": $(jq -n 'now | todate')
}
EOF
) >"$VSCODE_OUT_PATH/product.json"
) > "$VSCODE_OUT_PATH/product.json"

# We remove the scripts field so that later on we can run
# yarn to fetch node_modules if necessary without build scripts running.
# We cannot use --no-scripts because we still want dependent package scripts to run.
jq 'del(.scripts)' <"$VSCODE_SRC_PATH/package.json" >"$VSCODE_OUT_PATH/package.json"
jq 'del(.scripts)' < "$VSCODE_SRC_PATH/package.json" > "$VSCODE_OUT_PATH/package.json"

pushd "$VSCODE_OUT_PATH"
symlink_asar
Expand Down
2 changes: 1 addition & 1 deletion ci/build/build-standalone-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ main() {
# we use the same version it's using so we instead run a script with yarn that
# will print the path to node.
local node_path
node_path="$(yarn -s node <<<'console.info(process.execPath)')"
node_path="$(yarn -s node <<< 'console.info(process.execPath)')"

mkdir -p "$RELEASE_PATH/bin"
rsync ./ci/build/code-server.sh "$RELEASE_PATH/bin/code-server"
Expand Down
20 changes: 10 additions & 10 deletions ci/build/npm-postinstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ set -eu
# Copied from arch() in ci/lib.sh.
detect_arch() {
case "$(uname -m)" in
aarch64)
echo arm64
;;
x86_64 | amd64)
echo amd64
;;
*)
# This will cause the download to fail, but is intentional
uname -m
;;
aarch64)
echo arm64
;;
x86_64 | amd64)
echo amd64
;;
*)
# This will cause the download to fail, but is intentional
uname -m
;;
esac
}

Expand Down
2 changes: 1 addition & 1 deletion ci/build/release-github-draft.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ main() {
gh release create "v$VERSION" \
--notes-file - \
--target "$(git rev-parse HEAD)" \
--draft <<EOF
--draft << EOF
v$VERSION

VS Code v$(vscode_version)
Expand Down
10 changes: 5 additions & 5 deletions ci/build/release-prep.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,31 +20,31 @@ main() {
cd "$(dirname "$0")/../.."

# Check that gh is installed
if ! command -v gh &>/dev/null; then
if ! command -v gh &> /dev/null; then
echo "gh could not be found."
echo "We use this with the release-github-draft.sh and release-github-assets.sh scripts."
echo -e "See docs here: https://github.com/cli/cli#installation"
exit
fi

# Check that they have jq installed
if ! command -v jq &>/dev/null; then
if ! command -v jq &> /dev/null; then
echo "jq could not be found."
echo "We use this to parse the package.json and grab the current version of code-server."
echo -e "See docs here: https://stedolan.github.io/jq/download/"
exit
fi

# Check that they have rg installed
if ! command -v rg &>/dev/null; then
if ! command -v rg &> /dev/null; then
echo "rg could not be found."
echo "We use this when updating files across the codebase."
echo -e "See docs here: https://github.com/BurntSushi/ripgrep#installation"
exit
fi

# Check that they have node installed
if ! command -v node &>/dev/null; then
if ! command -v node &> /dev/null; then
echo "node could not be found."
echo "That's surprising..."
echo "We use it in this script for getting the package.json version"
Expand All @@ -53,7 +53,7 @@ main() {
fi

# Check that gh is authenticated
if ! gh auth status -h github.com &>/dev/null; then
if ! gh auth status -h github.com &> /dev/null; then
echo "gh isn't authenticated to github.com."
echo "This is needed for our scripts that use gh."
echo -e "See docs regarding authentication: https://cli.github.com/manual/gh_auth_login"
Expand Down
18 changes: 9 additions & 9 deletions ci/dev/fmt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ main() {
git ls-files "${prettierExts[@]}" | grep -v "lib/vscode" | grep -v 'helm-chart'
)

doctoc --title '# FAQ' docs/FAQ.md >/dev/null
doctoc --title '# Setup Guide' docs/guide.md >/dev/null
doctoc --title '# Install' docs/install.md >/dev/null
doctoc --title '# npm Install Requirements' docs/npm.md >/dev/null
doctoc --title '# Contributing' docs/CONTRIBUTING.md >/dev/null
doctoc --title '# Maintaining' docs/MAINTAINING.md >/dev/null
doctoc --title '# Contributor Covenant Code of Conduct' docs/CODE_OF_CONDUCT.md >/dev/null
doctoc --title '# iPad' docs/ipad.md >/dev/null
doctoc --title '# Termux' docs/termux.md >/dev/null
doctoc --title '# FAQ' docs/FAQ.md > /dev/null
doctoc --title '# Setup Guide' docs/guide.md > /dev/null
doctoc --title '# Install' docs/install.md > /dev/null
doctoc --title '# npm Install Requirements' docs/npm.md > /dev/null
doctoc --title '# Contributing' docs/CONTRIBUTING.md > /dev/null
doctoc --title '# Maintaining' docs/MAINTAINING.md > /dev/null
doctoc --title '# Contributor Covenant Code of Conduct' docs/CODE_OF_CONDUCT.md > /dev/null
doctoc --title '# iPad' docs/ipad.md > /dev/null
doctoc --title '# Termux' docs/termux.md > /dev/null

if [[ ${CI-} && $(git ls-files --other --modified --exclude-standard) ]]; then
echo "Files need generation or are formatted incorrectly:"
Expand Down
4 changes: 2 additions & 2 deletions ci/dev/gen_icons.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ main() {
# This escapes all newlines so that sed will accept them.
favicon_dark_style="$(printf "%s\n" "$favicon_dark_style" | sed -e ':a' -e 'N' -e '$!ba' -e 's/\n/\\n/g')"
sed "$(
cat -n <<EOF
cat -n << EOF
s%<rect id="favicon"%$favicon_dark_style<rect id="favicon"%
EOF
)" favicon.svg >favicon-dark-support.svg
)" favicon.svg > favicon-dark-support.svg
}

main "$@"
2 changes: 1 addition & 1 deletion ci/dev/lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ main() {
stylelint $(git ls-files "*.css" | grep -v "lib/vscode")
tsc --noEmit --skipLibCheck
shellcheck -e SC2046,SC2164,SC2154,SC1091,SC1090,SC2002 $(git ls-files "*.sh" | grep -v "lib/vscode")
if command -v helm && helm kubeval --help >/dev/null; then
if command -v helm && helm kubeval --help > /dev/null; then
helm kubeval ci/helm-chart
fi

Expand Down
8 changes: 4 additions & 4 deletions ci/dev/update-vscode.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ main() {

# Check if the remote exists
# if it doesn't, we add it
if ! git config remote.vscode.url >/dev/null; then
if ! git config remote.vscode.url > /dev/null; then
echo "Could not find 'vscode' as a remote"
echo "Adding with: git remote add vscode https://github.com/microsoft/vscode.git"
git remote add vscode https://github.com/microsoft/vscode.git
Expand All @@ -52,7 +52,7 @@ main() {
fi

# Check that they have jq installed
if ! command -v jq &>/dev/null; then
if ! command -v jq &> /dev/null; then
echo "jq could not be found."
echo "We use this when looking up the exact version to update to in the package.json in VS Code."
echo -e "See docs here: https://stedolan.github.io/jq/download/"
Expand All @@ -62,7 +62,7 @@ main() {
# Note: `git subtree` returns 129 when installed, and prints help;
# but when uninstalled, returns 1.
set +e
git subtree &>/dev/null
git subtree &> /dev/null
if [ $? -ne 129 ]; then
echo "git-subtree could not be found."
echo "We use this to fetch and update the lib/vscode subtree."
Expand All @@ -83,7 +83,7 @@ main() {
git fetch vscode

# Check if GitHub CLI is installed
if ! command -v gh &>/dev/null; then
if ! command -v gh &> /dev/null; then
echo "GitHub CLI could not be found."
echo "If you install it before you run this script next time, we'll open a draft PR for you!"
echo -e "See docs here: https://github.com/cli/cli#installation\n"
Expand Down
24 changes: 12 additions & 12 deletions ci/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
set -euo pipefail

pushd() {
builtin pushd "$@" >/dev/null
builtin pushd "$@" > /dev/null
}

popd() {
builtin popd >/dev/null
builtin popd > /dev/null
}

pkg_json_version() {
Expand Down Expand Up @@ -37,15 +37,15 @@ os() {
arch() {
cpu="$(uname -m)"
case "$cpu" in
aarch64)
echo arm64
;;
x86_64 | amd64)
echo amd64
;;
*)
echo "$cpu"
;;
aarch64)
echo arm64
;;
x86_64 | amd64)
echo amd64
;;
*)
echo "$cpu"
;;
esac
}

Expand Down Expand Up @@ -85,7 +85,7 @@ download_artifact() {
local tmp_file
tmp_file="$(mktemp)"

gh api "$(get_artifact_url "$artifact_name")" >"$tmp_file"
gh api "$(get_artifact_url "$artifact_name")" > "$tmp_file"
unzip -q -o "$tmp_file" -d "$dst"
rm "$tmp_file"
}
Expand Down
2 changes: 1 addition & 1 deletion ci/release-image/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ eval "$(fixuid -q)"
if [ "${DOCKER_USER-}" ]; then
USER="$DOCKER_USER"
if [ "$DOCKER_USER" != "$(whoami)" ]; then
echo "$DOCKER_USER ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/nopasswd >/dev/null
echo "$DOCKER_USER ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/nopasswd > /dev/null
# Unfortunately we cannot change $HOME as we cannot move any bind mounts
# nor can we bind mount $HOME into a new home as that requires a privileged container.
sudo usermod --login "$DOCKER_USER" coder
Expand Down
2 changes: 1 addition & 1 deletion ci/steps/brew-bump.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ main() {
echo "Pushing changes to cdrci/homebrew-core fork on GitHub"
# Source: https://serverfault.com/a/912788
# shellcheck disable=SC2016,SC2028
echo '#!/bin/sh\nexec echo "$HOMEBREW_GITHUB_API_TOKEN"' >"$HOME"/.git-askpass.sh
echo '#!/bin/sh\nexec echo "$HOMEBREW_GITHUB_API_TOKEN"' > "$HOME"/.git-askpass.sh
# Ensure it's executable since we just created it
chmod +x "$HOME/.git-askpass.sh"
# GIT_ASKPASS lets us use the password when pushing without revealing it in the process list
Expand Down
2 changes: 1 addition & 1 deletion ci/steps/publish-npm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ main() {
source ./ci/lib.sh

if [[ ${CI-} ]]; then
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" >~/.npmrc
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
fi

download_artifact npm-package ./release-npm-package
Expand Down
Loading