From f0e6ba6b8c4c719c57c93b6bf845c344e14d9f58 Mon Sep 17 00:00:00 2001 From: Paul Taylor <178183+trxcllnt@users.noreply.github.com> Date: Tue, 20 Aug 2024 09:58:50 -0700 Subject: [PATCH] Ensure `common-utils` rc snippets end with newlines (#1100) ensure common-utils rc snippets have line endings --- src/common-utils/devcontainer-feature.json | 2 +- src/common-utils/scripts/bash_theme_snippet.sh | 2 +- src/common-utils/scripts/devcontainers.zsh-theme | 4 ++-- src/common-utils/scripts/rc_snippet.sh | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/common-utils/devcontainer-feature.json b/src/common-utils/devcontainer-feature.json index 153e2503d..968cbfb77 100644 --- a/src/common-utils/devcontainer-feature.json +++ b/src/common-utils/devcontainer-feature.json @@ -1,6 +1,6 @@ { "id": "common-utils", - "version": "2.5.0", + "version": "2.5.1", "name": "Common Utilities", "documentationURL": "https://github.com/devcontainers/features/tree/main/src/common-utils", "description": "Installs a set of common command line utilities, Oh My Zsh!, and sets up a non-root user.", diff --git a/src/common-utils/scripts/bash_theme_snippet.sh b/src/common-utils/scripts/bash_theme_snippet.sh index 6e80952a4..ab76ada33 100644 --- a/src/common-utils/scripts/bash_theme_snippet.sh +++ b/src/common-utils/scripts/bash_theme_snippet.sh @@ -41,4 +41,4 @@ if [[ "$TERM" == "xterm" ]]; then # Append to PROMPT_COMMAND to call precmd before displaying the prompt PROMPT_COMMAND="${PROMPT_COMMAND:+$PROMPT_COMMAND; }precmd" -fi \ No newline at end of file +fi diff --git a/src/common-utils/scripts/devcontainers.zsh-theme b/src/common-utils/scripts/devcontainers.zsh-theme index d12993a67..0cfd70e65 100644 --- a/src/common-utils/scripts/devcontainers.zsh-theme +++ b/src/common-utils/scripts/devcontainers.zsh-theme @@ -1,7 +1,7 @@ # Oh My Zsh! theme - partly inspired by https://github.com/ohmyzsh/ohmyzsh/blob/master/themes/robbyrussell.zsh-theme __zsh_prompt() { local prompt_username - if [ ! -z "${GITHUB_USER}" ]; then + if [ ! -z "${GITHUB_USER}" ]; then prompt_username="@${GITHUB_USER}" else prompt_username="%n" @@ -42,4 +42,4 @@ if [[ "$TERM" == "xterm" ]]; then autoload -Uz add-zsh-hook add-zsh-hook preexec preexec add-zsh-hook precmd precmd -fi \ No newline at end of file +fi diff --git a/src/common-utils/scripts/rc_snippet.sh b/src/common-utils/scripts/rc_snippet.sh index 42249ecbd..f3f36a4b8 100644 --- a/src/common-utils/scripts/rc_snippet.sh +++ b/src/common-utils/scripts/rc_snippet.sh @@ -16,9 +16,9 @@ fi # Set the default git editor if not already set if [ -z "$(git config --get core.editor)" ] && [ -z "${GIT_EDITOR}" ]; then if [ "${TERM_PROGRAM}" = "vscode" ]; then - if [[ -n $(command -v code-insiders) && -z $(command -v code) ]]; then + if [[ -n $(command -v code-insiders) && -z $(command -v code) ]]; then export GIT_EDITOR="code-insiders --wait" - else + else export GIT_EDITOR="code --wait" fi fi