diff --git a/package.json b/package.json index e8d84933f59..5e1db5afec5 100644 --- a/package.json +++ b/package.json @@ -17,9 +17,6 @@ "format": "prettier --write .", "format-check": "prettier --check .", "heroku-postbuild": "chmod u+x scripts/heroku-build.sh && ./scripts/heroku-build.sh", - "lint-all": "NODE_OPTIONS=\"--max-old-space-size=4096\" eslint './packages/**/*.{ts,tsx}'", - "lint-branch": "./scripts/lint-branch.sh", - "lint-branch-warnings": "FAIL_WARNINGS=1 ./scripts/lint-branch.sh", "load-db": "pnpm -F commonwealth load-db", "migrate-db": "pnpm -F commonwealth migrate-db", "prepare": "husky install", diff --git a/scripts/lint-branch.sh b/scripts/lint-branch.sh deleted file mode 100755 index 036955f4412..00000000000 --- a/scripts/lint-branch.sh +++ /dev/null @@ -1,25 +0,0 @@ -# The base branch is provided by GitHub Actions. If it's not set, default to "master". -BASE_BRANCH=${GITHUB_BASE_REF:-master} - -# Fetch the base branch only if this script is running in GitHub Actions -# and the base branch hasn't been fetched yet -if [ -n "$GITHUB_BASE_REF" ]; then - if ! git show-ref --quiet refs/remotes/origin/$BASE_BRANCH; then - git fetch origin $BASE_BRANCH - fi -fi - -# Get a list of changed .ts files -LINES=$(git diff origin/$BASE_BRANCH...HEAD --name-only --diff-filter=d | grep -E '\.tsx?$' | grep -v 'libs/chains/src/cosmos-ts/') - -if [ -z "$LINES" ] -then - echo "There is nothing to lint" -else - echo $LINES - if [ -n "$FAIL_WARNINGS" ]; then - NODE_OPTIONS="--max-old-space-size=8192" eslint --max-warnings=0 $LINES --no-ignore - else - NODE_OPTIONS="--max-old-space-size=8192" eslint $LINES - fi -fi