branch: elpa/javelin
commit d3ab274737eaf414ba8aea5e838f51f2a1134a62
Author: Otávio Schwanck dos Santos <[email protected]>
Commit: Otávio Schwanck dos Santos <[email protected]>

    improve harpoon
---
 README.org | 12 +++++++-----
 harpoon.el |  4 ++++
 2 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/README.org b/README.org
index 32cae6c78ac..adb2eaed312 100644
--- a/README.org
+++ b/README.org
@@ -64,13 +64,15 @@ Example of how to set the shortcuts:
 * Customizing
 You can customize by setting this variable:
 
-| Variable                         | Description                               
                                            | Default                          |
-| harpoon-separate-by-branch       | If nil, ignores the branch                
                                            | t                                |
-| harpoon-project-package          | Package used to harpoon to get project 
stuff.  Available: projectile, project         | 'projectile                    
  |
-| harpoon-without-project-function | Function used to return a name for 
harpoon cache file when not visiting a project. | 
'harpoon--current-file-directory |
+| Variable                         | Description                               
                                         | Default                |
+| harpoon-separate-by-branch       | If nil, ignores the branch                
                                         | t                      |
+| harpoon-project-package          | Package used to harpoon to get project 
stuff.  Available: projectile, project      | 'projectile            |
+| harpoon-without-project-function | Function used to return a name for 
harpoon cache file when not visiting a project. | 'harpoon--package-name |
 
 ** Extra tips for ~harpoon-without-project-function~
-If you use doom (with persp-mode), you can use '+workspace-current-name and 
use the workspace name instead current file directory.
+If you want that harpoon behaves uses the current file directory, change it to 
'harpoon--current-file-directory
+
+If you use doom , you can set this variable to '+workspace-current-name and 
use the workspace name instead the harpoon global.
 
 You can also create your own function to determine the harpoon cache file and 
add to this variable.
 
diff --git a/harpoon.el b/harpoon.el
index 4bfaca1dd39..7be36473f2c 100644
--- a/harpoon.el
+++ b/harpoon.el
@@ -225,6 +225,10 @@
   (if (file-exists-p (harpoon--file-name))
       (f-read (harpoon--file-name) 'utf-8) ""))
 
+(defun harpoon--package-name ()
+  "Return harpoon package name."
+  "harpoon")
+
 ;;;###autoload
 (defun harpoon-toggle-file ()
   "Open harpoon file."

Reply via email to