Coder Social home page Coder Social logo

Comments (3)

MikeMcQuaid avatar MikeMcQuaid commented on June 29, 2024 1

I'm not sure how things are sorted currently

It's a topological sort. The ordering is important as otherwise you'll install dependencies in the not the order specified in the Brewfile.

but could it be done on package name?

It could but, due to the above, it should not be.

from homebrew-bundle.

paddyroddy avatar paddyroddy commented on June 29, 2024

It's a topological sort. The ordering is important as otherwise you'll install dependencies in the not the order specified in the Brewfile.

Fair enough. Although, I think that as long as tap remains at the top then it's fine. FWIW I have done the following:

#!/usr/bin/env bash
BREW_FILE=$HOME/.Brewfile
BREW_TYPES=(
    tap
    brew
    cask
    mas
)
TMP_FILE=/tmp/.Brewfile_unsorted

# update homebrew list
brew bundle dump --force --file $TMP_FILE

# sort the final output
## clear current contents
> $BREW_FILE
for type in ${BREW_TYPES[@]}; do
    ## extract lines starting with "type" and sort them
    grep --dereference-recursive "^${type}" $TMP_FILE | sort >> $BREW_FILE
done
## remove temporary file
rm $TMP_FILE

from homebrew-bundle.

MikeMcQuaid avatar MikeMcQuaid commented on June 29, 2024

then it's fine

It's fine if you're happy for dependencies to be installed not when the Brewfile things they will be but before that and the error messages to not be clear about what package has failed to install.

from homebrew-bundle.

Related Issues (20)

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.