Cleaning up the cibuild stuff.
This commit is contained in:
		
							parent
							
								
									9d07a97945
								
							
						
					
					
						commit
						ab66326f97
					
				| 
						 | 
				
			
			@ -2,4 +2,4 @@
 | 
			
		|||
 | 
			
		||||
script/branding
 | 
			
		||||
script/proof
 | 
			
		||||
bundle exec rake
 | 
			
		||||
script/test
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
							
								
								
									
										29
									
								
								script/proof
								
								
								
								
							
							
						
						
									
										29
									
								
								script/proof
								
								
								
								
							| 
						 | 
				
			
			@ -1,19 +1,20 @@
 | 
			
		|||
#! /bin/bash
 | 
			
		||||
#
 | 
			
		||||
# Usage:
 | 
			
		||||
#   script/proof
 | 
			
		||||
 | 
			
		||||
# Check if any site files have changed
 | 
			
		||||
if [[ $(git diff --name-only origin $(git log --pretty=format:"%h" -2 | tail -1) | grep '^/site') == "" ]]; then
 | 
			
		||||
	echo "No site files changed"
 | 
			
		||||
	exit 0
 | 
			
		||||
fi
 | 
			
		||||
git diff --name-only origin $(git log --pretty=format:"%h" -2 | tail -1) | grep '^/site' || {
 | 
			
		||||
    echo "No site files changed. We'll skip proofing."
 | 
			
		||||
    exit 0
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
# Site files have been changed, continue
 | 
			
		||||
echo "Site files have been changed, proofing"
 | 
			
		||||
if ! [[ $(command -v htmlproof) ]]; then
 | 
			
		||||
	echo "Installing HTML::Proofer"
 | 
			
		||||
	gem install html-proofer -- --use-system-libraries
 | 
			
		||||
fi
 | 
			
		||||
echo "Some site files have been changed! Proofing..."
 | 
			
		||||
 | 
			
		||||
printf "\nGenerating site...     "
 | 
			
		||||
jekyll build -s site -d _site -q
 | 
			
		||||
printf "done.\n\n\e[0;36mProofing begins now!\e[0m\n"
 | 
			
		||||
command -v htmlproof || {
 | 
			
		||||
    echo "Installing HTML::Proofer!"
 | 
			
		||||
    gem install html-proofer -- --use-system-libraries
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
jekyll build -s site -d _site --trace
 | 
			
		||||
echo -e "\e[0;36mProofing begins now!\e[0m\n"
 | 
			
		||||
htmlproof ./_site
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
							
								
								
									
										13
									
								
								script/test
								
								
								
								
							
							
						
						
									
										13
									
								
								script/test
								
								
								
								
							| 
						 | 
				
			
			@ -1,11 +1,20 @@
 | 
			
		|||
#! /bin/bash
 | 
			
		||||
#
 | 
			
		||||
# Usage:
 | 
			
		||||
#   script/test
 | 
			
		||||
#   script/test <hi>
 | 
			
		||||
 | 
			
		||||
set -x
 | 
			
		||||
git diff --name-only origin $(git log --pretty=format:"%h" -2 | tail -1) | grep -v '^/site' || {
 | 
			
		||||
    echo "No lib files have changed, skipping Jekyll tests!"
 | 
			
		||||
    exit 0
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
if [ -z "$1" ]; then
 | 
			
		||||
  TEST_FILES="test/test*.rb"
 | 
			
		||||
  TEST_FILES="test/test_*.rb"
 | 
			
		||||
else
 | 
			
		||||
  TEST_FILES="$@"
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
set -x
 | 
			
		||||
 | 
			
		||||
/usr/bin/env bundle exec ruby -I"lib:test" -r rake -r rake/rake_test_loader ${TEST_FILES}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue