aboutsummaryrefslogtreecommitdiff
path: root/tools/fix_headers.rb
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2017-12-25 21:35:49 +0100
committerAqua-sama <aqua@iserlohn-fortress.net>2017-12-25 21:35:49 +0100
commit6186990d9bcbfe344dd701caef781c4472439d6b (patch)
tree2c0060c9f3dfc7038404127501649f258281a897 /tools/fix_headers.rb
parent--profile no longer causes a crash (diff)
downloadsmolbote-6186990d9bcbfe344dd701caef781c4472439d6b.tar.xz
Updated pre-commit hook
Diffstat (limited to 'tools/fix_headers.rb')
-rwxr-xr-xtools/fix_headers.rb18
1 files changed, 0 insertions, 18 deletions
diff --git a/tools/fix_headers.rb b/tools/fix_headers.rb
deleted file mode 100755
index 6d23ed6..0000000
--- a/tools/fix_headers.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/usr/bin/ruby
-
- # for all files
-
-file_names = Dir.glob("**/*.h") + Dir.glob("**/*.cpp")
-new_header = File.read('new_header')
-old_header = File.read('old_header')
-
-file_names.each do |file_name|
- text = File.read(file_name)
- new_contents = text.gsub(old_header, new_header)
-
- # To merely print the contents of the file, use:
- #puts new_contents
-
- # To write changes to the file, use:
- File.open(file_name, "w") {|file| file.puts new_contents }
-end