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

Add the possibility of using more than one extension eg. {'.md', '.qmd'} [FR] #337

Open
1 task done
ertwro opened this issue Jul 7, 2024 · 1 comment · May be fixed by #339
Open
1 task done

Add the possibility of using more than one extension eg. {'.md', '.qmd'} [FR] #337

ertwro opened this issue Jul 7, 2024 · 1 comment · May be fixed by #339
Assignees
Labels
enhancement New feature or request

Comments

@ertwro
Copy link

ertwro commented Jul 7, 2024

Please confirm

  • I am running the latest version of this plugin

While I understand that Telekasten has its own filetype and its various abilities stem from being distinct from markdown, it still uses the markdown file extension. However, there are multiple markdown extension files, and if I want to use more than one extension, I either need another vault or have to modify my configuration each time. In the configuration file, when I set the extension type, I can only select one at a time.

    require('telekasten').setup {
      home = vim.fn.expand '~/zettelkasten', -- Put the name of your notes directory here
      -- Launch panel if nothing is typed after <leader>z
      vim.keymap.set('n', '<leader>zz', '<cmd>Telekasten panel<CR>'),
      -- Call insert link automatically when we start typing a link
      vim.keymap.set('i', '[[', '<cmd>Telekasten insert_link<CR>'),
      extension = '.md',
      -- extension = '.qmd',
      -- extension = '.rmd',
      -- extension = {'.rmd', '.md', '.qmd'},
    }

Instead of expecting a string, please allow the addition of a table.
This way we can use more than one extension for the Telekasten filetype, like this.

      extension = {'.rmd', '.md', '.qmd'},

Thanks in advance.

@ertwro ertwro added the enhancement New feature or request label Jul 7, 2024
@lambtho12
Copy link
Member

This should not be too complicated too add indeed. Although it is rather low priority for now as most contributors have little time.
If you are interested, you can propose a PR and I will review it as quickly as I can.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants