mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-09-10 17:13:50 +02:00
Merge pull request #1 from ostera/markdown-lint
Makefile improvements and Gemfile addition
This commit is contained in:
commit
db18071a2c
4 changed files with 32 additions and 7 deletions
3
Gemfile
Normal file
3
Gemfile
Normal file
|
@ -0,0 +1,3 @@
|
|||
source 'https://rubygems.org'
|
||||
|
||||
gem 'mdl'
|
16
Gemfile.lock
Normal file
16
Gemfile.lock
Normal file
|
@ -0,0 +1,16 @@
|
|||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
kramdown (1.7.0)
|
||||
mdl (0.2.1)
|
||||
kramdown (~> 1.5, >= 1.5.0)
|
||||
mixlib-cli (~> 1.5, >= 1.5.0)
|
||||
mixlib-config (~> 2.1, >= 2.1.0)
|
||||
mixlib-cli (1.5.0)
|
||||
mixlib-config (2.1.0)
|
||||
|
||||
PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
mdl
|
18
Makefile
18
Makefile
|
@ -1,18 +1,24 @@
|
|||
all: setup index
|
||||
|
||||
index:
|
||||
@TLDRHOME=`pwd` ./scripts/build_index.rb
|
||||
@echo "Index rebuilt."
|
||||
|
||||
setup:
|
||||
setup: hooks deps
|
||||
|
||||
hooks:
|
||||
@cp ./scripts/pre-commit .git/hooks
|
||||
@chmod +x .git/hooks/pre-commit
|
||||
@echo "Git pre-commit hook installed."
|
||||
|
||||
deps:
|
||||
@bundle
|
||||
@echo "OK"
|
||||
|
||||
@gem install mdl --install-dir .gem --no-rdoc --no-ri
|
||||
@echo "Installed required Ruby gems under .gem"
|
||||
|
||||
lint:
|
||||
lint:
|
||||
@GEM_PATH=.gem find pages -exec .gem/bin/mdl {} --style ./scripts/markdown-style.rb 1>&2 \;
|
||||
|
||||
lint-changed:
|
||||
@./scripts/lint-changed.sh
|
||||
|
||||
|
||||
.PHONY: index setup hooks deps lint lint-changed
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Add table
Reference in a new issue