skywind3000 / emake

你见过的最简单的 GCC/CLANG 项目构建工具,定义式构建,比命令式更简单
GNU General Public License v2.0
684 stars 111 forks source link

建议在homebrew发布 #15

Open LomotHo opened 4 years ago

LomotHo commented 4 years ago

macos10.15不能修改系统文件了,并且也不想用sudo安装,能不能发布一个homebrew的版本

skywind3000 commented 4 years ago

弄不来 homebrew,怎么弄啊?

LomotHo commented 4 years ago

刚刚试了一下,已经放到自己的brew仓库里面去了,你可以试着push到homebrew-core

lomot@lomot-Mac ~ brew search emake
==> Formulae
libpagemaker                        lomotho/taps/emake ✔                premake                             remake                              snakemake

我发布在私有仓库的具体步骤:

  1. 创建github项目 LomotHo/homebrew-taps
  2. git clone git@github.com:LomotHo/homebrew-taps.git
    cd homebrew-taps
    mkdir Formula
  3. 添加emake.rb
    // 此命令会在/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula下生成emake.rb
    brew create https://github.com/LomotHo/emake/archive/3.6.9.tar.gz
    // 链接是github release中复制的

    修改emake.rb中install部分,如下:(需要提前在emake项目下把emake.py复制一份为emake,我fork了一份)

    def install
    bin.install "emake"
    end
  4. 复制emake.rb 修改完emake.rb后可以把/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula中的emake.rb复制一份到自己仓库homebrew-taps中,我是直接mv过来的,然后提交git修改。

之后就可以从brew 安装了:

brew install lomotho/taps/emake
  1. 提交到homebrew-core,这个没尝试

我参考的是这篇文章:https://mogeko.me/2019/046/