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

Unwind with company-abort in counsel-company #1793

Merged
merged 1 commit into from Oct 30, 2018

Conversation

@mnick
Copy link
Contributor

commented Oct 28, 2018

Currently, the company tooltip popup appears after aborting counsel-company with C-g or ESC (see also #1650). This is a simple patch that fixes this by adding company-abort to the unwind of counsel-company.

@abo-abo abo-abo merged commit bd980d8 into abo-abo:master Oct 30, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@abo-abo

This comment has been minimized.

Copy link
Owner

commented Oct 30, 2018

Thanks.

@tarsius

This comment has been minimized.

Copy link
Contributor

commented on bd980d8 Nov 11, 2018

@mnick Could you please declare this function like the other company-* functions are already.

@abo-abo On the subject of the compiler complaining; there are a few instances of this warning:

Warning: ‘org-get-tags-string’ is an obsolete function (as
    of Org 9.2); use ‘org-make-tag-string’ instead.

You could use a function like this to address this:

(defun counsel--org-make-tag-string ()
  (if (fboundp #'org-make-tag-string) ; >= Org 9.2
      (org-make-tag-string (org-get-tags nil t))
    (with-no-warnings
      (org-get-tags-string))))

This comment has been minimized.

Copy link
Owner

replied Nov 11, 2018

@tarsius Thanks, please review d76968a.

This comment has been minimized.

Copy link
Contributor

replied Nov 11, 2018

I think this is wrong:

-(split-string (org-get-tags-string) ":" t)
+(org-get-tags)

it should be

-(split-string (org-get-tags-string) ":" t)
+(org-get-tags nil t)

Otherwise you switch from returning the tags of this heading to returning those plus the ones that it inherits.

This comment has been minimized.

Copy link
Owner

replied Nov 12, 2018

Otherwise you switch from returning the tags of this heading to returning those plus the ones that it inherits.

I have an Org version that's a bit outdated. Here's the definition that I have right now:

(defun org-get-tags ()
  "Get the list of tags specified in the current headline."
  (org-split-string (org-get-tags-string) ":"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.