aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/disktype.rb
blob: b39b51afa4867a302acf299cc8d51c064b1d3845 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
class Disktype < Formula
  homepage 'http://disktype.sourceforge.net/'
  head ":pserver:anonymous:@disktype.cvs.sourceforge.net:/cvsroot/disktype", :using => :cvs
  url 'https://downloads.sourceforge.net/project/disktype/disktype/9/disktype-9.tar.gz'
  sha1 '5ccc55d1c47f9a37becce7336c4aa3a7a43cc89c'

  def install
    system "make"
    bin.install "disktype"
    man1.install "disktype.1"
  end

  test do
    path = testpath/"foo"
    path.write "1234"

    output = shell_output("#{bin}/disktype #{path}")
    assert output.include?("Regular file, size 4 bytes")
  end
end