rust-raspberrypi-OS-tutorials/utils/clippy_all.rb

19 lines
277 B
Ruby
Raw Normal View History

2018-04-13 20:07:30 +00:00
#!/usr/bin/env ruby
2018-12-29 23:20:24 +00:00
def clippy_all
crates = Dir["*/Cargo.toml"].sort!
crates.delete_if { |x| x.include?('bareminimum') }
2018-04-13 20:07:30 +00:00
2018-12-29 23:20:24 +00:00
crates.each do |x|
x = File.dirname(x)
2018-04-13 20:07:30 +00:00
2018-12-29 23:20:24 +00:00
Dir.chdir(x) do
system('make clippy')
end
2018-04-13 20:07:30 +00:00
end
end
2018-12-29 23:20:24 +00:00
if __FILE__ == $0
clippy_all()
end