Skip to content

Instantly share code, notes, and snippets.

View Dragotic's full-sized avatar
🦖

Alexios Polyzos Dragotic

🦖
  • Greece
  • 20:39 (UTC +03:00)
View GitHub Profile
@antonbabenko
antonbabenko / .bash_profile
Last active May 2, 2023 11:24
Make your terragrunt output useful
# Put this function in your ~/.bash_profile or similar and use `terragrunt` as before.
# From: https://github.com/gruntwork-io/bash-commons/blob/master/modules/bash-commons/src/array.sh
# Returns 0 if the given item (needle) is in the given array (haystack); returns 1 otherwise.
array_contains() {
local -r needle="$1"
shift
local -ra haystack=("$@")
local item