فهرست منبع

Removed gitlint code for now

Daniel Gibbs 10 سال پیش
والد
کامیت
f5458419ab
13فایلهای تغییر یافته به همراه0 افزوده شده و 195 حذف شده
  1. 0 3
      .gitmodules
  2. 0 8
      build/.shippable.yml
  3. 0 8
      build/.travis.yml
  4. 0 22
      build/LICENSE
  5. 0 75
      build/README.md
  6. 0 45
      build/build.sh
  7. 0 10
      build/install.sh
  8. 0 8
      build/shippable.yml.example
  9. 0 2
      build/tests/bash.sh
  10. 0 2
      build/tests/ksh.sh
  11. 0 2
      build/tests/sh.sh
  12. 0 2
      build/tests/zsh.sh
  13. 0 8
      build/travis.yml.example

+ 0 - 3
.gitmodules

@@ -1,3 +0,0 @@
-[submodule "build"]
-	path = build
-	url = https://github.com/caarlos0/shell-ci-build.git

+ 0 - 8
build/.shippable.yml

@@ -1,8 +0,0 @@
-language: ruby
-install:
-  - ./install.sh
-script:
-  - ./build.sh
-notifications:
-  email: false
-sudo: required

+ 0 - 8
build/.travis.yml

@@ -1,8 +0,0 @@
-language: bash
-install:
-  - ./install.sh
-script:
-  - ./build.sh
-notifications:
-  email: false
-sudo: required

+ 0 - 22
build/LICENSE

@@ -1,22 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) 2014 Carlos Alexandro Becker
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-SOFTWARE.
-

+ 0 - 75
build/README.md

@@ -1,75 +0,0 @@
-shell-ci-build [![Build Status](https://travis-ci.org/caarlos0/shell-ci-build.svg?branch=master)](https://travis-ci.org/caarlos0/shell-ci-build)
-==================
-
-A submodule to lint your shell projects with shellcheck in travis.ci builds.
-
-## Build
-
-- The `install.sh` script will install shellckeck.
-- The `build.sh` will lint all executable files with shellcheck, avoiding
-Ruby, compdef and the like files. It will also ignore all files inside `.git`
-directory and files of your `gitmodules`, if any.
-
-## Usage
-
-```sh
-git submodule add https://github.com/caarlos0/shell-ci-build.git build
-cp build/travis.yml.example .travis.yml
-```
-
-We also support Shippable:
-
-```
-cp build/shippable.yml.example .shippable.yml
-```
-
-Or tweak your `.travis.yml` to be like this:
-
-```yml
-language: bash
-install:
-  - ./build/install.sh
-script:
-  - ./build/build.sh
-```
-
-## Customizing
-
-You might want to lint other files, to do that, you need your own
-`build.sh` and a slight change in `.travis.yml` file.
-
-Example (from  my [dotfiles](https://github.com/caarlos0/dotfiles)):
-
-```sh
-#!/usr/bin/env bash
-set -eo pipefail
-source ./build/build.sh
-check "./zsh/zshrc.symlink"
-```
-
-```yml
-language: bash
-install:
-  - ./build/install.sh
-script:
-  - ./build.sh
-notifications:
-  email: false
-```
-
-This will make travis ran the `build.sh` from this project first,
-then, lint your custom files.
-
-You can also override the `find_cmd` function, which returns a string
-containing the `find` command to `eval`. Check the source or open an
-issue if you have any problems.
-
-## Updating
-
-Update your projects is easy. Just run this:
-
-```sh
-git submodule update --remote --merge && \
-  git commit -am 'updated shell-ci-build version' && \
-  git push
-```

+ 0 - 45
build/build.sh

@@ -1,45 +0,0 @@
-#!/usr/bin/env bash
-set -eo pipefail
-[[ "${DEBUG:-}" ]] && set -x
-
-success() {
-  printf "\r\033[2K  [ \033[00;32mOK\033[0m ] Linting %s...\n" "$1"
-}
-
-fail() {
-  printf "\r\033[2K  [\033[0;31mFAIL\033[0m] Linting %s...\n" "$1"
-  exit 1
-}
-
-check() {
-  local script="$1"
-  shellcheck "$script" || fail "$script"
-  success "$script"
-}
-
-find_prunes() {
-  local prunes="! -path './.git/*'"
-  if [ -f .gitmodules ]; then
-    while read module; do
-      prunes="$prunes ! -path './$module/*'"
-    done < <(grep path .gitmodules | awk '{print $3}')
-  fi
-  echo "$prunes"
-}
-
-find_cmd() {
-  echo "find . -type f -and \( -perm +111 -or -name '*.sh' \) $(find_prunes)"
-}
-
-check_all_executables() {
-  echo "Linting all executables and .sh files, ignoring files inside git modules..."
-  eval "$(find_cmd)" | while read script; do
-    head=$(head -n1 "$script")
-    [[ "$head" =~ .*ruby.* ]] && continue
-    [[ "$head" =~ .*zsh.* ]] && continue
-    [[ "$head" =~ ^#compdef.* ]] && continue
-    check "$script"
-  done
-}
-
-check_all_executables

+ 0 - 10
build/install.sh

@@ -1,10 +0,0 @@
-#!/bin/bash
-set -eo pipefail
-
-main() {
-  local filename="shellcheck_0.3.7-1_amd64.deb"
-  wget "http://ftp.debian.org/debian/pool/main/s/shellcheck/$filename"
-  sudo dpkg -i "$filename"
-}
-
-main

+ 0 - 8
build/shippable.yml.example

@@ -1,8 +0,0 @@
-language: ruby
-install:
-  - ./build/install.sh
-script:
-  - ./build/build.sh
-notifications:
-  email: false
-sudo: required

+ 0 - 2
build/tests/bash.sh

@@ -1,2 +0,0 @@
-#!/bin/bash
-echo "hi"

+ 0 - 2
build/tests/ksh.sh

@@ -1,2 +0,0 @@
-#!/bin/ksh
-echo "hi"

+ 0 - 2
build/tests/sh.sh

@@ -1,2 +0,0 @@
-#!/bin/sh
-echo "hi"

+ 0 - 2
build/tests/zsh.sh

@@ -1,2 +0,0 @@
-#!/bin/zsh
-echo "hi"

+ 0 - 8
build/travis.yml.example

@@ -1,8 +0,0 @@
-language: bash
-install:
-  - ./build/install.sh
-script:
-  - ./build/build.sh
-notifications:
-  email: false
-sudo: required