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

libcouchbase3 3.0 (new formula) #49103

Closed
wants to merge 1 commit into from
Closed

libcouchbase3 3.0 (new formula) #49103

wants to merge 1 commit into from

Conversation

avsej
Copy link
Contributor

@avsej avsej commented Jan 17, 2020

This is a clone of libcouchbase.rb. Libcouchbase 3 represent new version of the library with backwards incompatible API.

We still going to maintain and release fixes for libcouchbase 2.x, this is why I don't make changes in Formula/libcouchbase.rb

This is a clone of libcouchbase.rb. Libcouchbase 3 represent new version
of the library with backwards incompatible API.
@SMillerDev
Copy link
Member

The highest version number should always have the main name. libcouchbase in this case. The old version should be overwritten and can optionally be reinstated if there is enough of a demand.

@@ -0,0 +1,28 @@
class Libcouchbase3 < Formula
desc "C library for Couchbase"
homepage "https://docs.couchbase.com/c-sdk/3.0/hello-world/start-using-sdk.html"
Copy link
Member

Choose a reason for hiding this comment

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

Please use the normal homepage.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

What is wrong with this home page? Why it is not normal?

Copy link
Member

Choose a reason for hiding this comment

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

This is a specific document. It's not a homepage.

Choose a reason for hiding this comment

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

It's the homepage for this particular library. We could also send them to the README on github, but the page pointed to here is the best intro for most developers.

end

test do
system "#{bin}/cbc", "version"
Copy link
Member

Choose a reason for hiding this comment

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

We need a test that exercises the some of the functionality of the app. Version checks or usage checks (foo --version or foo --help) are not sufficient, as explained in the formula cookbook.

In most cases, a good test would involve running a simple test case: run #{bin}/foo input.txt.

  • Then you can check that the output is as expected (with assert_equal or assert_match on the output of shell_output)
  • You can also check that an output file was created, if that is expected: assert_predicate testpath/"output.txt", :exist?

Some advice for specific cases:

  • If the formula is a library, compile and run some simple code that links against it. It could be taken from upstream's documentation / source examples.
  • If the formula is for a GUI program, try to find some function that runs as command-line only, like a format conversion, reading or displaying a config file, etc.
  • If the software cannot function without credentials, a test could be to try to connect with invalid credentials (or without credentials) and confirm that it fails as expected.
  • Same if the software requires a virtual machine, docker instance, etc. to be running.

@bayandin bayandin added the new formula PR adds a new formula to Homebrew/homebrew-core label Jan 18, 2020
@chenrui333 chenrui333 changed the title libcouchbase3: new formula libcouchbase3 3.0 (new formula) Jan 31, 2020
@stale
Copy link

stale bot commented Feb 21, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added stale No recent activity and removed stale No recent activity labels Feb 21, 2020
@stale
Copy link

stale bot commented Mar 13, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the stale No recent activity label Mar 13, 2020
@stale stale bot closed this Mar 20, 2020
@lock lock bot added the outdated PR was locked due to age label Apr 25, 2020
@lock lock bot locked as resolved and limited conversation to collaborators Apr 25, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
new formula PR adds a new formula to Homebrew/homebrew-core outdated PR was locked due to age stale No recent activity
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants