mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-01-24 17:27:50 -05:00
Quick-and-dirty script to catch an error we've missed a couple of times in code review, but which is not (AFAICT) covered by any of our existing checkers. Inspired by the following posts: - https://zachholman.com/posts/how-github-writes-blog-posts/ - https://zachholman.com/talk/move-fast-break-nothing/
10 lines
306 B
Ruby
Executable File
10 lines
306 B
Ruby
Executable File
#!/usr/bin/env ruby
|
|
|
|
require 'set'
|
|
|
|
changed_file_list = `git diff --name-only --diff-filter=ACMRTUXB origin/dev...`
|
|
files = Set.new changed_file_list.split
|
|
if (files.include? "Gemfile") && !(files.include? "Gemfile.lock") then
|
|
abort "Looks like you committed changes to Gemfile but not Gemfile.lock"
|
|
end
|