VSCode – Markdown Edition
blog.dendron.so
blog.dendron.so
Adding Prettier (https://marketplace.visualstudio.com/items?itemName=esbenp.p...) for its underdiscussed Markdown formatting keeps READMEs and blog posts clean as well.
The extension functionality does look great though. I wrote some similar functions in my nvim which I would have really a hard time living without.
I'm not a VSCode user myself, but it's pretty much the same story with nvim.
edit: I suppose what I'm really getting at, is that, depending on what their security measures look like, the VSCode extension store might be giving some false sense of security.
I suppose I could mention that on a Mac, I use Objective-See’s tools to watch what programs do in the background. And also on a Mac, you have to grant access to apps first otherwise they can’t normally access files. Of course, that breaks down in reality as most apps are useless if they can’t access files.
If you really want a scare, consider that if you compromise an ecosystem package (e.g. npm), you can run on developer machines, CI systems and possibly in production, while if you compromise a VS Code extension, you only get dev machines.
If you’re looking for a bit of extra protection, you can run VS Code from a virtual machine or even run it from Docker. Though the usual docker approach, using remote containers extension, still runs on your local computer. There’s GitHub Codespaces or Google Cloud Shell that can run VS Code remotely in a VM, though.
Just sprinkling bits of awareness around by bringing some of these considerations up whenever I can. It's an uphill battle, although, the general carelessness around extension and dependency use I'm seeing - and that even after all the shit that's been going on in that space - makes it one worth to fight.
Edit: Regarding the chain of trust you mention, that one has sort of come and gone, and there is not a whole lot of trust involved in the processes I'm saddled up with.
Programs should run as their own users. Programs should be granted access to files opened via system (desktop environment) file picker APIs or when passed in via a shell. Desktop environments & shells would need to be modified to allow this, of course.
> Programs should be granted access to files opened via system (desktop environment) file picker APIs or when passed in via a shell.
For example, this would render the file tree of any IDE or advanced editor (like VS code) completely useless. I can count on one hand the number of times I've used the system file picker when programming.
Not sure if I consider vim either simple or sane, but then again, it was first released quite a while ago, in 1991 for the Amiga, and it was based on the even older original vi from 1971 - the era of physical TTYs, no mice, and punchcard programming (ugh! glad I wasn't born yet).
Can hardly blame grandpa for forgetting and acting strange every once in a while at his age :)
When grandpa refuses to wear glasses even though he can't see jack then it's time to take his car's key off of his hands.
0: https://marketplace.visualstudio.com/items?itemName=telesoho...
https://marketplace.visualstudio.com/items?itemName=dendron....
And I've finally found my comfort in a folder with a certain directory structure containing all markdown files. I use VSCode for this (as it's already my daily driver) and GitJournal in Android to manage sync via git.
These features are a huge value addition to my workflow!
After reading more about dendron which states on https://github.com/dendronhq/dendron "It's a personal knowledge management solution (PKM) built specifically for developers and integrates natively with IDEs like VS Code and VSCodium." , the question is how these tools could serve a wider audience if they were packaged more as standalone app (using something like Eclipse Theia).
This makes it easy to publish your notes as a static site. The plan is to add optional server side capabilities here so that it becomes possible to read *and* write notes, at which point it becomes a web interface for note taking. It also helps with the distribution problem (Dendron is used by teams to publish documentation to non-technical folks so it helps that they can access it as a regular webpage)
the reason we went with it is because: - it allows a file to be both a note and a parent of notes - it makes hierarchy an explicit part of note creation - it greatly simplified operations like refactoring (regex over filename, no need to create scaffolding with empty folders or removing folders if they no longer had children) - it makes it easy to work with using cli tools
More discussion on this here: - https://wiki.dendron.so/notes/683740e3-70ce-4a47-a1f4-1f140e... - https://wiki.dendron.so/notes/683740e3-70ce-4a47-a1f4-1f140e...
(also, disclaimer: I'm the author of the article and founder of Dendron)
VS Code is a text-editor focused on coding. Obsidian is a markdown-editor focused on knowledge- and self-management. They are each hard to beat in their own specialty. For example, the WYSIWYG-Editor of obsidian is not something that VS Codes raw text-view can beat, especially if you combine it with add-ons for code-blocks.
I found out that I end up doing a lot of editing + file organisation tricks native to my VSCode setup. So +1 to kevinslin's sibling comment.
[0]: https://obsidian.md/
- Advanced Tables: for automatic formatting and table operations of markdown tables
- Dynamic Table of Contents: allows you to include a codeblock that automatically renders a table of contents from headers of some level
- Natural language dates: insert dates in your preferred format using language like 'next Friday' or 'first Monday of June'
- Quick latex for Obsidian: autoformat and autocomplete common latex commands (e.g. 'a/b' becomes '\frac{b}{a}'
- Tag Wrangler: rename, merge, toggle and search tags easily
- Sliding Panes: changes notes to panes that can be stacked similar to the ui of Andy Matushchak's notes [0] (check it out, it's rather neat)
- Zoom: Work on part of a bullet list structure in isolation, with a breadcrumb line at the top to jump to a different parent level
- Copy button for code blocks
- Auto backup with Git
- Outliner: Vertical indentation lines for bullet lists, and hotkeys to move list items about in the structure
- Recent files: List of files, ordered by most recently opened
- Vimrc support
Not a plugin, but I tried to make a cheatsheet of the supported Prism language types that I'm likely to use. They can be specified in the code fences (```) so that the code and config blocks in my markdown notes look prettier : https://prismjs.com/#supported-languages
- Convert to iframe (transform a pasted URL into a iframe)
- Custom attachment location (so pasting a screenshot automatically stores it in a dedicated subfolder)
- Core search assistant (to preview search results)
- Reveal Active File (to find the current note in the LHS tree)
- Mind map (show the outline of a note as a mind map)
- Excalidraw (draw things in notes)
- Outline (adds a Outline side panel)
And I plan to investigate:
- obsidian-annotator
But not for most markdown files, at least how I use it. I only start new line (actually, 2 new lines) when I reach a new paragraph, and I think this is normal for most people who ever write something in markdown.
So now I get a huge 2000 character line with a few small edits, and I can hardly see where the changes are.
I wish github would also implement word-diff option.
Edit: Github actually does some form of word-diff! See example here: https://github.com/chaoxu/chaoxu.github.io/commit/6d9ab6eefc...
I also looked up how word-diff work with Chinese language. Found a useful stackoverflow link with other suggestions.
https://stackoverflow.com/questions/26135133/git-word-diff-o...
I recognize that I am not normal and this doesn't contradict your assumption, but I use Emacs' fill command to hard-wrap long lines at ~80 characters when I'm writing Markdown. In fact, it's so habitual for me that it causes me problems when writing Gemtext. I keep meaning to disable filling in gemini-mode.
Markdown treats lines separated with a single line break as a continuous line/the same paragraph, and you need to add two or more newlines for Markdown to interpret it as a new paragraph.
Git works just fine with Markdown.
But how does someone take advantage of it without changing their current behavior: write an entire paragraph and do 2 line breaks.
Always end a sentence with '.\n'? Manually format lines so no line have more than 80 characters?
Prettier options to extensions like Rewrap, one of those might fit your use case.
I don't understand your question. Markdown's syntax already requires 2+ newlines to define a paragraph. There should be no change in a workflow if you're already using Markdown.
The only nuance is that if you want git to track changes in each sentence that forms a paragraph, just add a single line break after the punctuation mark. Markdown still interprets that as the same text block, but git is able to handle changes per line.
Nice heads-up to look out for.
Working Copy works decently well on iOS. Gollum [1] on desktop operating systems provides a web interface to the notes. For some shameless self-promotion, I’ve been hacking on a clone of Gollum called Smeagol [2]. It is written in Rust so it is quite a bit faster to install and run on some of my low powered systems than installing Gollum.
[1]: https://github.com/gollum/gollum [2]: https://smeagol.dev/
Works great and straight forward to setup.
i'm currently working on shipping the publishing side of dendron in a docker (its a custom nextjs app) so that it can be easily tested locally as well as hosted remotely
(taoofmac.com is like that, and is actually a pretty big wiki)
I've been resisting hacking my own, but I suspect I will eventually have to :)
Not OP but, personally, I was very disappointed when I found out that Loqseq doesn't support free-form text / Markdown as it's an outliner (only).
What issues did you encounter with Dendron? Would appreciate feedback so we can make it better!
I never did figure out what was going wrong, but I moved to Obsidian mainly so I had a clear separate note keeping app.
This is nice, but I'd really prefer being able to drag and drop and then have it uploaded to, say, OneDrive. Even better, be able to paste a URL and have it download the file and then upload it to OneDrive or Dropbox or whatever.
> find all references to header|links|files|urls inside of markdown
Sometimes this sort of thing is nice to have, but doesn't it add a lot of overhead when working with markdown files?
what year are you? is mcmurtry still in-tents?