diff --git a/.bldr.toml b/.bldr.toml index 5742472cef..3e9a59a21e 100644 --- a/.bldr.toml +++ b/.bldr.toml @@ -1070,6 +1070,8 @@ plan_path = "serf" plan_path = "shadow" [shared-mime-info] plan_path = "shared-mime-info" +[shellcheck] +plan_path = "shellcheck" [shield] plan_path = "shield" [shield-agent] diff --git a/shellcheck/README.md b/shellcheck/README.md new file mode 100644 index 0000000000..33b91f21df --- /dev/null +++ b/shellcheck/README.md @@ -0,0 +1,15 @@ +# shellcheck + +ShellCheck is a GPLv3 tool that gives warnings and suggestions for bash/sh shell scripts. + +## Maintainers + +* The Habitat Maintainers: + +## Type of Package + +Binary package + +## Usage + +*TODO: Add instructions for usage* diff --git a/shellcheck/plan.sh b/shellcheck/plan.sh new file mode 100644 index 0000000000..80076c6237 --- /dev/null +++ b/shellcheck/plan.sh @@ -0,0 +1,48 @@ +pkg_name=shellcheck +hkg_name=ShellCheck +pkg_origin=core +pkg_version=0.5.0 +pkg_license=('GPL-3') +pkg_upstream_url="http://www.shellcheck.net/" +pkg_description="ShellCheck is a GPLv3 tool that gives warnings and suggestions for bash/sh shell scripts" +pkg_maintainer="The Habitat Maintainers " +pkg_source="https://hackage.haskell.org/package/${hkg_name}-${pkg_version}/${hkg_name}-${pkg_version}.tar.gz" +pkg_shasum="2b9430736f48de17a60c035546a6a969c14392521bec30119e1c869017d3307c" +pkg_dirname="${hkg_name}-${pkg_version}" + +pkg_bin_dirs=(bin) +pkg_lib_dirs=(lib) + +pkg_deps=( + core/glibc + core/gmp + core/libffi +) + +pkg_build_deps=( + core/cabal-install + core/ghc +) + +do_clean() { + do_default_clean + + # Strip any previous cabal config + rm -rf /root/.cabal +} + +do_build() { + cabal sandbox init + cabal update + + # Install dependencies + cabal install --only-dependencies + + # Configure and Build + cabal configure --prefix="$pkg_prefix" + cabal build +} + +do_install() { + cabal copy +}