salarkhan / git-pear

swap credentials after each commit
3 stars 0 forks source link

Add homebrew installation method #36

Open salarkhan opened 10 years ago

salarkhan commented 10 years ago

brew pear vs brew git-pear

relevant links

salarkhan commented 10 years ago

About the first line above:

was wondering if we should just change the name to pear for homebrew...? unless we can somehow upload it as git-pear && have it be executed by calling pear

salarkhan commented 10 years ago

Short version of how to upload to brew:

Fork Homebrew.
brew create http://example.com/foo-0.1.tar.gz
git checkout -b foo
git commit Library/Formula/foo.rb && git push
PR to Homebrew

Here's the problem. In line 2 of the above, we have to have a tarball of git-pear. Does that mean we have to ensure that we create && commit a tarball every time we push to master? ( i'm assuming we'd just host it within the repo )

Btw I figured out how to make a tarball: tar cvfz pear.tgz git-pear/

salarkhan commented 10 years ago

@supertopher

All you need to make a formula is a URL to the tarball.

Where the hell can I host a tarball..?

salarkhan commented 10 years ago

wait lol it's dropbox time

salarkhan commented 10 years ago

We will reject formulae that seem too obscure, partly because they won’t get maintained and partly because we have to draw the line somewhere.

We frown on authors submitting their own work unless it is very popular.

Errrrr this might be a deterrant. Repo prob needs more than 5 stars to pass this requirement lolol

supertopher commented 10 years ago

i think github will create a tar ball for us from the repo.

also i can get some students to star the repo for us

supertopher commented 10 years ago

this will download the repo and untar it curl -L https://github.com/salarkhan/git-pear/tarball/master | tar zx

this is the link https://github.com/salarkhan/git-pear/tarball/master

salarkhan commented 10 years ago

here's my formula

require "formula"

class Pear < Formula
  homepage "https://www.dropbox.com/s/c1fublkznjtbnbi/pear.tar.gz?dl=1"
  url "zX"
  sha1 "97e81ccd523e8dfa7bfd49bbb4187de554764c1a"
  version "0.0"

  depends_on :x11

  def install
    system "./install"
  end
end

here's my error. how the heck am i supposed to run the install script within pear..? the first thing i printed there is the pwd when the formula's install method runs the second thing is all the files inside there.

neither of them make sense to me

i've looked at other formula and it seems like people are using Makefiles

screen shot 2014-09-17 at 9 47 22 pm

salarkhan commented 10 years ago

also crazy find with https://github.com/salarkhan/git-pear/tarball/master btw, thats super dope