Code Monkey home page Code Monkey logo

sh-syntax's People

Contributors

github-actions[bot] avatar jlarmstrongiv avatar jounqin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

sh-syntax's Issues

Node type

Hello,

Thank you for providing the WASM version of mvdan-sh. Is there a way to obtain the node type?

[sh] error `offset is out of bounds`

via un-ts/prettier#182 (comment)

#!/usr/bin/env bash
set -euo pipefail

stage_path="$(dirname "$(realpath -s "$0")")/../../globals.stage"

# git on vercel https://vercel.com/docs/concepts/deployments/build-step#build-image

# check if program does not exist https://stackoverflow.com/a/26759734
# check if in github repo https://stackoverflow.com/a/16925062
if [[ ! -x "$(command -v git)" ]] || [[ $(git rev-parse --is-inside-work-tree 2> /dev/null) != "true" ]]; then
    # check if file does not exist https://linuxize.com/post/bash-check-if-file-exists/
    if [[ ! -f "globals.stage" ]]; then
        if [[ ! -x "$(command -v git)" ]]; then
            echo '[stage]: git is not installed.' >&2
            exit 1
        else
            echo '[stage]: not a git repository.' >&2
            exit 1
        fi
    else
        stage=$(cat "globals.stage")
        # trim newlines https://stackoverflow.com/a/12973694
        # trim whitespace https://stackoverflow.com/a/13092379
        stage=$(echo "$stage" | xargs)
        echo "$stage"
        exit 0
    fi
fi

# current git branch https://stackoverflow.com/a/1593487
branch_name=$(git symbolic-ref -q HEAD)
branch_name=${branch_name##refs/heads/}
branch_name=${branch_name:-HEAD}

# bash kebab-case https://stackoverflow.com/a/56080830
branch_name=$(echo "$branch_name" \
    | sed 's/\([^A-Z]\)\([A-Z0-9]\)/\1-\2/g' \
    | sed 's/\([A-Z0-9]\)\([A-Z0-9]\)\([^A-Z]\)/\1-\2\3/g' \
    | tr '[:upper:]' '[:lower:]')

monorepo_path="$("$(dirname "$(realpath -s "$0")")/../functions/monorepo_path")"
# extract json key https://unix.stackexchange.com/questions/480481/grep-the-name-from-package-json-file#comment1308267_691616
base_branch="$(grep -o '"baseBranch"\s*:\s*"[^"]*' "$monorepo_path/turbo.json" | grep -o '[^"]*$')"
base_branch="${base_branch##*/}"

# if statement https://www.tutorialkart.com/bash-shell-scripting/bash-else-if/
if [[ "$branch_name" == "production" ]]; then
    echo '[stage]: "production" is not a valid branch name' >&2
    exit 1
fi

if [[ "$branch_name" == "$base_branch" ]]; then
    branch_name="production"
fi

# noclobber https://stackoverflow.com/a/56138414
set -o noclobber
echo "$branch_name" >| "$stage_path"

echo "$branch_name"

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Repository problems

These problems occurred while renovating this repository.

  • WARN: Using npm packages for Renovate presets is now deprecated. Please migrate to repository-based presets instead.

Awaiting Schedule

These updates are awaiting their schedule. Click on a checkbox to get an update now.

  • chore(deps): update dependency @types/mvdan-sh to ^0.10.5
  • chore(deps): update dependency @types/node to ^20.4.9
  • chore(deps): update dependency @types/web to ^0.0.112
  • chore(deps): update pnpm to v8.6.12
  • fix(deps): update dependency tslib to ^2.6.1
  • chore(deps): update dependency go to 1.21
  • chore(deps): update node.js to >=v16.20.1
  • chore(deps): update vitest monorepo to ^0.34.1 (@vitest/coverage-istanbul, vitest)
  • fix(deps): update module mvdan.cc/sh/v3 to v3.7.0
  • chore(deps): update node.js to v18

Detected dependencies

github-actions
.github/workflows/ci.yml
  • actions/checkout v3
  • pnpm/action-setup v2
  • actions/setup-node v3
  • codecov/codecov-action v3
.github/workflows/codeql.yml
  • actions/checkout v3
  • github/codeql-action v2
  • github/codeql-action v2
  • github/codeql-action v2
.github/workflows/release.yml
  • actions/checkout v3
  • pnpm/action-setup v2
  • actions/setup-node v3
  • changesets/action v1
.github/workflows/size-limit.yml
  • actions/checkout v3
  • pnpm/action-setup v2
  • actions/setup-node v3
  • andresz1/size-limit-action v1
gomod
go.mod
  • go 1.20
  • github.com/mailru/easyjson v0.7.7
  • mvdan.cc/sh/v3 v3.6.0
npm
package.json
  • tslib ^2.6.0
  • @1stg/lib-config ^12.0.0
  • @changesets/changelog-github ^0.4.8
  • @changesets/cli ^2.26.2
  • @types/golang-wasm-exec ^1.15.0
  • @types/mvdan-sh ^0.10.2
  • @types/node ^20.4.0
  • @types/web ^0.0.103
  • @vitest/coverage-istanbul ^0.32.4
  • mitata ^0.1.6
  • mvdan-sh ^0.10.1
  • size-limit ^8.2.6
  • size-limit-preset-node-lib ^0.2.0
  • synckit ^0.8.5
  • type-coverage ^2.26.0
  • typescript ^5.1.6
  • vitest ^0.32.4
  • node >=16.0.0
  • pnpm 8.6.6
nvm
.nvmrc
  • node 18

  • Check this box to trigger a request for Renovate to run again on this repository

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.