Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add more possible Brew paths #39

Closed
buresdv opened this issue Mar 10, 2023 · 25 comments
Closed

Add more possible Brew paths #39

buresdv opened this issue Mar 10, 2023 · 25 comments
Assignees
Labels
Bug Something isn't working Enhancement New feature or request

Comments

@buresdv
Copy link
Owner

buresdv commented Mar 10, 2023

In some instances, the path to the brew command might be different, for example when Homebrew is installed through Git instead of their script. See https://elk.zone/glasgow.social/@sandy/109998976036176844

As the brew command is alsu used extensively, it would be a good idea to include it in AppConstants instead of having to write it out every time.

Proposed fix:

  1. Add the path to the Brew command to AppConstants
  2. Implement a system for checking which path is correct
  3. Add an option to choose the location of Brew in settings, perhaps in the General tab
@buresdv buresdv self-assigned this Mar 10, 2023
@buresdv buresdv added Bug Something isn't working Enhancement New feature or request labels Mar 10, 2023
@jmb
Copy link

jmb commented Mar 10, 2023

FYI... This also applies to these lines in App Constants.swift:

    static let brewCellarPath: URL = URL(string: "/opt/homebrew/Cellar")!
    static let brewCaskPath: URL = URL(string: "/opt/homebrew/Caskroom")!

Hope this helps!

@buresdv
Copy link
Owner Author

buresdv commented Mar 10, 2023

What are those two paths for you? So I know

@sandydunlop
Copy link

sandydunlop commented Mar 10, 2023 via email

@buresdv
Copy link
Owner Author

buresdv commented Mar 10, 2023

@sandydunlop could you test the newest build from branch multiple-brew-paths?

@jmb, once @sandydunlop confirms that the fix is working, I will also implement it in your macOS 12 build.

@jmb
Copy link

jmb commented Mar 10, 2023

Yes, also /usr/local

@sandydunlop
Copy link

sandydunlop commented Mar 10, 2023 via email

@buresdv
Copy link
Owner Author

buresdv commented Mar 10, 2023

Of course, no worries!

@sandydunlop
Copy link

sandydunlop commented Mar 10, 2023 via email

@buresdv
Copy link
Owner Author

buresdv commented Mar 10, 2023

Amazing, good to hear! I will merge it into main in that case.

@jmb I will update your macOS 12 build to implement this fix and then tell you when it's done

@buresdv
Copy link
Owner Author

buresdv commented Mar 10, 2023

@jmb Here's your macOS 12 version with the fix implemented. I have also implemented fixes for #20 and #38, which were not a part of your original build, but I wanted to fix them for you :)
Cork.zip

@buresdv
Copy link
Owner Author

buresdv commented Mar 10, 2023

The option for choosing your own paths is not implemented, perhaps in the future. This fix should cover all possible cases, unless the user does something batshit like moving the executable manually and not symlinking it.

@buresdv buresdv closed this as completed Mar 10, 2023
@sandydunlop
Copy link

sandydunlop commented Mar 10, 2023 via email

@buresdv
Copy link
Owner Author

buresdv commented Mar 10, 2023

No worries, and I thank you for your support :)

@jmb
Copy link

jmb commented Mar 11, 2023

@jmb Here's your macOS 12 version with the fix implemented. I have also implemented fixes for #20 and #38, which were not a part of your original build, but I wanted to fix them for you :)
Cork.zip

Thank you this is amazing!

@buresdv
Copy link
Owner Author

buresdv commented Mar 17, 2023

Hey guys, could you please run brew tap-info homebrew/core and send me the output? I'm working on faster loading of Taps and I need to know where they are located for you, so this new system works for you
@jmb @sandydunlop

@buresdv buresdv reopened this Mar 17, 2023
@jmb
Copy link

jmb commented Mar 17, 2023

Here you go:

$ brew tap-info homebrew/core
homebrew/core: 3 commands, 6540 formulae
/usr/local/Homebrew/Library/Taps/homebrew/homebrew-core (6,995 files, 557.5MB)
From: https://github.com/Homebrew/homebrew-core

@buresdv buresdv closed this as completed Mar 17, 2023
@buresdv
Copy link
Owner Author

buresdv commented Mar 18, 2023

@jmb could you test this build if all the tap features work?
Cork_LD.zip

@sandydunlop can you test this build, again if the taps load and the adding/removing of taps works?
Cork.zip

@jmb
Copy link

jmb commented Mar 19, 2023

It's running ok, but I'm unsure what I need to test. If I click a tap in the left menu it doesn't show me any info, if I right-click kand choose "Remove", nothing happens.

When I click Update on the main screen to update my outdated packages, it says it's pulling updates, but also doesn't seem to do anything - the list remains. It does clear when I go and look at something else and come back.

@buresdv
Copy link
Owner Author

buresdv commented Mar 20, 2023

@jmb could you try running the branch lower-deployment-target from Xcode and seeing what errors it gives?

@buresdv buresdv reopened this Mar 20, 2023
@jmb
Copy link

jmb commented Mar 20, 2023

@jmb could you try running the branch lower-deployment-target from Xcode and seeing what errors it gives?

No major issues, the only minor error is [SwiftUI] No symbol named 'spigot' found in system symbol set.
👍🏻

@jmb
Copy link

jmb commented Mar 20, 2023

image

@buresdv
Copy link
Owner Author

buresdv commented Mar 20, 2023

I will try to fix that missing icon 😅 Apart from the icon, everything else works? Namely the problem with the taps and updating

@jmb
Copy link

jmb commented Mar 20, 2023

Updates all good. Taps don't seem to be left clickable - it would be handy to see the info about them. Looking at the console output in Xcode, I think it either needs to say what packages are installed that need removing first, or needs to ask if you want to remove those packages at the same time. Maybe a main panel screen with info about the tap would be helpful?

@buresdv
Copy link
Owner Author

buresdv commented Mar 20, 2023

Tap details are included in the main branch, but adding them came with a huge rewrite of the way Cork shows information, so I don't think I'll be able to backport that feature for you anymore.

I'll build the latest version of the app for you, but unfortunately, I think that will be as far as this backported version will ever go :(

@buresdv
Copy link
Owner Author

buresdv commented Mar 20, 2023

Here it is, I hope it will work:

Cork.zip

@buresdv buresdv closed this as completed Mar 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working Enhancement New feature or request
Projects
Status: Done
Development

When branches are created from issues, their pull requests are automatically linked.

3 participants