How to access data from `workspace:copy-path` in metabind

I would like to create a button with meta-bind, that allows me to create a note related to current note.

label: Work on this task
icon: pickaxe
hidden: false
class: ""
tooltip: Create a new note linked to this task
id: ""
style: primary
actions:
  - type: command
    command: workspace:copy-path
  - type: templaterCreateNote
    templateFile: Templates/WorkOnTask.md
    folderPath: Notes
    fileName: "{{date}}"
    openNote: true
  - type: sleep
    ms: 10
  - type: updateMetadata
    bindTarget: task_note
    evaluate: false
    value: "{{ workspace:file_path}}"    -- here i don't know how to access the value

I use workspace:copy-path to get filename of the note the button is clicked from, and i would like to add it to new note metadata, but don’t know how to retrieve the value…

I found that I can use <% tp.config.active_file.path%> in my template using Templater plugin, to retrieve the original file name the action was ran from

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.