Giter Club home page Giter Club logo

Comments (12)

michal-h21 avatar michal-h21 commented on June 11, 2024 1

We use Vimwiki's path-handling function and variables in many places in the code, so the changes would be big, and the possibility of breaking things would be big too. But as I said, I am not opposed to PR that enables it.

from vim-zettel.

michal-h21 avatar michal-h21 commented on June 11, 2024 1

Ah, OK, so I merged it. Thanks!

from vim-zettel.

ferdinandyb avatar ferdinandyb commented on June 11, 2024 1

@azthec if you're interested, can you check/test my PR #139 ?

from vim-zettel.

azthec avatar azthec commented on June 11, 2024

I agree that this should be a standard configuration.

If you want a work around I ended up splitting my vim-wiki into two so that this could be possible.

https://github.com/michal-h21/vim-zettel/blob/master/doc/zettel.txt#L254

from vim-zettel.

ferdinandyb avatar ferdinandyb commented on June 11, 2024

So your second vimwiki is a subfolder of the first? Do they play nicely together? Although I'm planning to spend a bit of time on a PR in the near future.

from vim-zettel.

azthec avatar azthec commented on June 11, 2024

Actually I have it setup as two separate wikis, in a git repository folder. However I tested and vim-zettel commands still work fine in subwiki like you said, as long as you change into the subwiki directory first.

This likely works due to the load order for the wikis https://github.com/michal-h21/vim-zettel/blob/master/doc/zettel.txt#L130

from vim-zettel.

michal-h21 avatar michal-h21 commented on June 11, 2024

The current code expects all notes to be in one directory. The trick with multiple wikis can prevent some errors, but I am not sure if everything works as expected. If anyone can fix this issue, I will gladly accept any PR!

from vim-zettel.

ferdinandyb avatar ferdinandyb commented on June 11, 2024

@michal-h21 My idea would be to simply allow the user to define a path relative to the vimwiki root to a specific folder where all of the zettels would go. Without having looked at the code yet, that seems like an easy fix as long as you know all the places where you need to prepend the path. E.g.

   let g:zettel_options = [{}, {"front_matter" : [["tags", ""], ["type","note"]],
   \ "template" :  "~/mytemplate.tpl", "zettel_dir": "subfolder/zettels"}]

would place all notes in /path/to/second/wiki/subfolder/zettels. I haven't yet looked at the code, but I hope it's not too complicated.

from vim-zettel.

ferdinandyb avatar ferdinandyb commented on June 11, 2024

I started looking at the code and yeah, it's not as straightforward as I thought, but let's see what I can come up with :)

from vim-zettel.

ferdinandyb avatar ferdinandyb commented on June 11, 2024

Do you mind if I open a WIP PR as I start hacking?

from vim-zettel.

michal-h21 avatar michal-h21 commented on June 11, 2024

Yes, it is not straightforward, it will need a lot of changes, but it can be an opportunity for some code cleanup.

So should I wait for the merging of your PR?

from vim-zettel.

ferdinandyb avatar ferdinandyb commented on June 11, 2024

I think #138 can be handled separately since as far as I see it, that seems to be a straightforward bugfix (at least it was not behaving as the docs says it should).

from vim-zettel.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.