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

Update SQL queries for compatibility with Bear v2 #54

Merged
merged 1 commit into from
Jul 12, 2023

Conversation

verginer
Copy link
Contributor

Hi,

I noticed that some of the SQL queries in alfred-bear are not compatible with the upcoming version 2 of Bear, which is expected to be released soon according to the beta forum. To ensure that alfred-bear continues to work properly with Bear v2, I have updated the queries based on the schema for Bear v2.

These queries have been tested and verified to work with Bear v2, but I would appreciate a check on some other machine, to be sure it works as expected.

I hope that these changes can be merged into the alfred-bear codebase to ensure that it remains compatible with the latest version of Bear. Please let me know if there are any issues with the changes or if there is anything else I can do to help.

Thank you!

@drgrib
Copy link
Owner

drgrib commented Mar 19, 2023

I appreciate you take the time to do this. But from what I have heard the names of some of these tables will change back to the old names in the release version (#52). If this still works when the release version is live, I'll merge it.

@xiaogaozi
Copy link

image

Based on the latest TestFlight version (Version 2.0 (10641)), the table name has changed.

@xiaogaozi
Copy link

I’ve tested this PR by compile the commands (e.g. search, create) manually, and it works as normal.

@rhazsolomon
Copy link

Hi there.

I'm unfamiliar with Go, would someone be okay to give instructions on how to use this new code while using the Bear 2.0 beta while waiting for this repo to get the official update :)

@xiaogaozi
Copy link

xiaogaozi commented Mar 27, 2023

@rhazsolomon The basic instructions are:

  1. Checkout this PR, click "Code" button in topmost for more information:

    image
  2. Install Go lang (e.g. brew install go)

  3. Change current directory to some command (e.g. cd cmd/search)

  4. Compile the command through go build, and it will produce a binary (e.g. search) in current directory.

  5. Open Alfred workflow directory (open "Alfred Preferences", switch to "Workflows", right click the "Bear" workflow, click "Open in Finder" or "Open in Terminal").

  6. Copy the new binary to Alfred workflow directory (e.g. cp search <alfred-bear-workflow-path>/cmd/search), overwrite the old binary.

@hongji3354
Copy link

@drgrib

Bear 2.0 is officially released today, any idea when we can expect to see a preview of that version?

@drgrib
Copy link
Owner

drgrib commented Jul 11, 2023

@hongji3354 I'll try to fit in the update and SQL compatibility merge tonight or tomorrow morning. I'm guessing this will just work based on the test runs from @xiaogaozi but the workflow is so critical to my daily job that I don't want to risk merging it until I have an open window to debug afterward if necessary.

@drgrib drgrib merged commit 0103b1c into drgrib:master Jul 12, 2023
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.

None yet

5 participants