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

Support for fetching formula directly from the project repo #9

Merged
merged 1 commit into from Mar 17, 2022
Merged

Support for fetching formula directly from the project repo #9

merged 1 commit into from Mar 17, 2022

Conversation

iawia002
Copy link
Collaborator

@iawia002 iawia002 commented Mar 17, 2022

close #4

I didn't use the method of determining if the repo exists first, since we are supporting two repo scenarios, there may be a repo in {package}-cask format but it is not used to store the Cask.toml file, this patch uses a simpler method and supports more scenarios, see my test results for https://github.com/iawia002/casktest-cask repo:

Fetching github.com/iawia002/casktest formula...
Downloading https://github.com/iawia002/lux/releases/download/v0.14.0/lux_0.14.0_macOS_64-bit.tar.gz
  [00:00:04] [###############################################################################################################################################################################################################] 13.79MiB/13.79MiB (3.41MiB/s, 0s)
The package 'github.com/iawia002/lux 0.14.0' has been installed!
Try run the command 'lux --help' to make sure it works!

Repo non-existent test:

Fetching github.com/iawia002/casktest1 formula...
It looks like the package does not support Cask
If you are the package owner, see our documentation for how to publish a package: https://github.com/axetroy/cask.rs/blob/main/DESIGN.md#how-do-i-publish-myothers-package
thread 'main' panicked at 'install package fail!: clone repository fail and exit code: 128

cc @axetroy I'll update the documentation if it's okay

@axetroy
Copy link
Member

axetroy commented Mar 17, 2022

need to run the make format to format the rust code

Copy link
Member

@axetroy axetroy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks

@axetroy axetroy merged commit 81d1f1c into cask-pkg:main Mar 17, 2022
@iawia002 iawia002 deleted the config-file-url branch March 17, 2022 07:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Why need a separate repo to store Cask.toml
2 participants