Skip to content
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

Go back to [ and switch to [[ instead of eq and ne #52

Merged
merged 3 commits into from
Sep 2, 2024
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 .github/workflows/configure-runner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
# Download and configure 'crave'.
- name: Configure the 'crave' environment
run: |
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
mkdir ${HOME}/bin/
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/force-restart-runner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
# Download and configure 'crave'.
- name: Configure the 'crave' environment
run: |
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
mkdir ${HOME}/bin/
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ jobs:
- name: Create Project Folders
run: |

if [ "${DCDEVSPACE}" != "1" ]; then
if [[ "${DCDEVSPACE}" != "1" ]]; then
echo "Symlinking devspace folder"
mkdir -p devspace
sudo mkdir -p /crave-devspaces
Expand All @@ -302,13 +302,13 @@ jobs:
else
echo "We are already running in devspace... Skipping Symlinks"
fi
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [ "${DCDEVSPACE}" -eq 1 ]; then
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone destroy -y $PROJECTFOLDER || echo "Error removing $PROJECTFOLDER"
else
echo "Skipping removal"
fi

if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone create --projectID $PROJECTID $PROJECTFOLDER || echo "Crave clone create failed!"
else
mkdir $PROJECTFOLDER
Expand Down Expand Up @@ -375,7 +375,7 @@ jobs:
- name: Configure the 'crave' environment
run: |
mkdir -p $PROJECTFOLDER/.repo/manifests
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
curl -s https://raw.githubusercontent.com/accupara/crave/master/get_crave.sh | bash -s --
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/selfhosted.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ jobs:
# Download and configure 'crave'.
- name: Configure the 'crave' environment
run: |
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
mkdir ${HOME}/bin/
Expand Down Expand Up @@ -351,7 +351,7 @@ jobs:
# Create a project folder
- name: Create Project Folders
run: |
if [ "${DCDEVSPACE}" -ne 1 ]; then
if [[ "${DCDEVSPACE}" != "1" ]]; then
echo "Symlinking devspace folder"
mkdir -p devspace
sudo mkdir -p /crave-devspaces
Expand All @@ -360,13 +360,13 @@ jobs:
else
echo "We are already running in devspace... Skipping Symlinks"
fi
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [ "${DCDEVSPACE}" -eq 1 ]; then
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone destroy -y $PROJECTFOLDER || echo "Error removing $PROJECTFOLDER"
else
echo "Skipping removal"
fi

if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone create --projectID $PROJECTID $PROJECTFOLDER || echo "Crave clone create failed!"
else
mkdir $PROJECTFOLDER
Expand Down Expand Up @@ -394,7 +394,7 @@ jobs:
- name: Configure the 'crave' environment
run: |
mkdir -p $PROJECTFOLDER/.repo/manifests
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
curl -s https://raw.githubusercontent.com/accupara/crave/master/get_crave.sh | bash -s --
Expand All @@ -420,7 +420,7 @@ jobs:
- name: Set the 'crave' project
run: |
cd $PROJECTFOLDER
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [ "${DCDEVSPACE}" -eq 1 ]; then
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [[ "${DCDEVSPACE}" == "1" ]]; then
echo "Using Crave Clone... skipping"
else
echo "Running $REPO_INIT"
Expand Down Expand Up @@ -562,7 +562,7 @@ jobs:
- name: Destroy Crave Clone
if: ${{ always() }}
run: |
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [ "${DCDEVSPACE}" -eq 1 ]; then
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone destroy -y $PROJECTFOLDER || echo "Error removing $PROJECTFOLDER"
else
echo "Skipping removal"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/start-vscode.obsolete
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
# Download and configure 'crave'.
- name: Configure the 'crave' environment
run: |
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
mkdir ${HOME}/bin/
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/twrp-legacy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ jobs:
- name: Create Project Folders
run: |

if [ "${DCDEVSPACE}" != "1" ]; then
if [[ "${DCDEVSPACE}" != "1" ]]; then
echo "Symlinking devspace folder"
mkdir -p devspace
sudo mkdir -p /crave-devspaces
Expand All @@ -229,13 +229,13 @@ jobs:
else
echo "We are already running in devspace... Skipping Symlinks"
fi
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [ "${DCDEVSPACE}" -eq 1 ]; then
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone destroy -y $PROJECTFOLDER || echo "Error removing $PROJECTFOLDER"
else
echo "Skipping removal"
fi

if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone create --projectID $PROJECTID $PROJECTFOLDER || echo "Crave clone create failed!"
else
mkdir $PROJECTFOLDER
Expand Down Expand Up @@ -302,7 +302,7 @@ jobs:
- name: Configure the 'crave' environment
run: |
mkdir -p $PROJECTFOLDER/.repo/manifests
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
curl -s https://raw.githubusercontent.com/accupara/crave/master/get_crave.sh | bash -s --
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/twrp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ jobs:
- name: Create Project Folders
run: |

if [ "${DCDEVSPACE}" != "1" ]; then
if [[ "${DCDEVSPACE}" != "1" ]]; then
echo "Symlinking devspace folder"
mkdir -p devspace
sudo mkdir -p /crave-devspaces
Expand All @@ -229,13 +229,13 @@ jobs:
else
echo "We are already running in devspace... Skipping Symlinks"
fi
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [ "${DCDEVSPACE}" -eq 1 ]; then
if grep -q "$PROJECTFOLDER" <(crave clone list --json | jq -r '.clones[]."Cloned At"') && [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone destroy -y $PROJECTFOLDER || echo "Error removing $PROJECTFOLDER"
else
echo "Skipping removal"
fi

if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
crave clone create --projectID $PROJECTID $PROJECTFOLDER || echo "Crave clone create failed!"
else
mkdir $PROJECTFOLDER
Expand Down Expand Up @@ -302,7 +302,7 @@ jobs:
- name: Configure the 'crave' environment
run: |
mkdir -p $PROJECTFOLDER/.repo/manifests
if [ "${DCDEVSPACE}" -eq 1 ]; then
if [[ "${DCDEVSPACE}" == "1" ]]; then
echo 'No need to set up crave, we are already running in devspace!'
else
curl -s https://raw.githubusercontent.com/accupara/crave/master/get_crave.sh | bash -s --
Expand Down