Coder Social home page Coder Social logo

Comments (7)

cjahv avatar cjahv commented on June 14, 2024 16
  1. HOMEBREW_EDITOR=vim brew edit tmignore
  2. write
class Tmignore < Formula
  desc "Exclude development files from Time Machine backups"
  homepage "https://github.com/samuelmeuli/tmignore"
  url "https://github.com/samuelmeuli/tmignore/releases/download/v1.2.2/tmignore"
  sha256 "80a8b0e3e05dc30113b9a4db1997b39fadfabbe2a58fa7f63ac4f757b2de9012"
  head "https://github.com/samuelmeuli/tmignore.git"

  depends_on :macos => :high_sierra

  def install
    bin.install "./tmignore"
    system "curl", "-L","-o", "#{prefix}/homebrew.tmignore.plist", "https://github.com/samuelmeuli/tmignore/raw/master/homebrew.tmignore.plist"
  end

  test do
    system "#{bin}/tmignore", "version"
  end
end
  1. brew install tmignore
  2. brew services start samuelmeuli/tap/tmignore

from tmignore.

llemllen avatar llemllen commented on June 14, 2024 2

The above didn’t work for me. Running brew services start samuelmeuli/tap/tmignore returned the following error:

Error: Formula `tmignore` has not implemented #plist, #service or installed a locatable service file

Adding mv "#{prefix}/homebrew.tmignore.plist", plist_path (as recommended here) got it working again:

NOTE: This only works after first trying the install script from the previous comment.
So the steps are:

  1. brew edit tmignore
  2. Replace with @cjahv’s script
  3. brew install tmignore
  4. brew edit tmignore
  5. Add “mv to plist_path” line like below
  6. brew reinstall tmignore
  7. brew services start tmignore
class Tmignore < Formula
  desc "Exclude development files from Time Machine backups"
  homepage "https://github.com/samuelmeuli/tmignore"
  url "https://github.com/samuelmeuli/tmignore/releases/download/v1.2.2/tmignore"
  sha256 "80a8b0e3e05dc30113b9a4db1997b39fadfabbe2a58fa7f63ac4f757b2de9012"
  head "https://github.com/samuelmeuli/tmignore.git"

  depends_on :macos => :high_sierra

  def install
    bin.install "./tmignore"
    system "curl", "-L","-o", "#{prefix}/homebrew.tmignore.plist", "https://github.com/samuelmeuli/tmignore/raw/master/homebrew.tmignore.plist"
    mv "#{prefix}/homebrew.tmignore.plist", plist_path
  end

  test do
    system "#{bin}/tmignore", "version"
  end
end

thank,it work on
Mac OS 12.3.1
Xcode 13.3.1

from tmignore.

fangzhengjin avatar fangzhengjin commented on June 14, 2024 2

I found a project that can replace this tool. It has GUI and complete functions.
https://github.com/PhotonQuantum/tmexclude

image

from tmignore.

elstgav avatar elstgav commented on June 14, 2024 1

The above didn’t work for me. Running brew services start samuelmeuli/tap/tmignore returned the following error:

Error: Formula `tmignore` has not implemented #plist, #service or installed a locatable service file

Adding mv "#{prefix}/homebrew.tmignore.plist", plist_path (as recommended here) got it working again:

NOTE: This only works after first trying the install script from the previous comment.
So the steps are:

  1. brew edit tmignore
  2. Replace with @cjahv’s script
  3. brew install tmignore
  4. brew edit tmignore
  5. Add “mv to plist_path” line like below
  6. brew reinstall tmignore
  7. brew services start tmignore
class Tmignore < Formula
  desc "Exclude development files from Time Machine backups"
  homepage "https://github.com/samuelmeuli/tmignore"
  url "https://github.com/samuelmeuli/tmignore/releases/download/v1.2.2/tmignore"
  sha256 "80a8b0e3e05dc30113b9a4db1997b39fadfabbe2a58fa7f63ac4f757b2de9012"
  head "https://github.com/samuelmeuli/tmignore.git"

  depends_on :macos => :high_sierra

  def install
    bin.install "./tmignore"
    system "curl", "-L","-o", "#{prefix}/homebrew.tmignore.plist", "https://github.com/samuelmeuli/tmignore/raw/master/homebrew.tmignore.plist"
    mv "#{prefix}/homebrew.tmignore.plist", plist_path
  end

  test do
    system "#{bin}/tmignore", "version"
  end
end

from tmignore.

fangzhengjin avatar fangzhengjin commented on June 14, 2024 1

This is effective on Mac OS 12.3.1

class Tmignore < Formula
  desc "Exclude development files from Time Machine backups"
  homepage "https://github.com/samuelmeuli/tmignore"
  url "https://github.com/samuelmeuli/tmignore/releases/download/v1.2.2/tmignore"
  sha256 "80a8b0e3e05dc30113b9a4db1997b39fadfabbe2a58fa7f63ac4f757b2de9012"
  head "https://github.com/samuelmeuli/tmignore.git"

  depends_on :macos => :high_sierra

  def install
    bin.install "./tmignore"
    system "curl", "-L","-o", plist_path, "https://github.com/samuelmeuli/tmignore/raw/master/homebrew.tmignore.plist"
  end

  test do
    system "#{bin}/tmignore", "version"
  end
end

from tmignore.

marijoo avatar marijoo commented on June 14, 2024 1

On Ventura 13.4.1 with Homebrew 4.1.23 I had to slightly modify the script mentioned by elstgav and use launchd_service_path instead of plist_path:

class Tmignore < Formula
    desc "Exclude development files from Time Machine backups"
    homepage "https://github.com/samuelmeuli/tmignore"
    url "https://github.com/samuelmeuli/tmignore/releases/download/v1.2.2/tmignore"
    sha256 "80a8b0e3e05dc30113b9a4db1997b39fadfabbe2a58fa7f63ac4f757b2de9012"
    head "https://github.com/samuelmeuli/tmignore.git"
    
    depends_on :macos => :high_sierra
    
    def install
        bin.install "./tmignore"
        system "curl", "-L","-o", "#{prefix}/homebrew.tmignore.plist", "https://github.com/samuelmeuli/tmignore/raw/master/homebrew.tmignore.plist"
        mv "#{prefix}/homebrew.tmignore.plist", launchd_service_path
    end
    
    test do
        system "#{bin}/tmignore", "version"
    end
end

from tmignore.

mfranzke avatar mfranzke commented on June 14, 2024

same for macOS Catalina (10.15.7)

from tmignore.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.