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

Don't modify whitespace. #295

Closed
naught101 opened this issue Feb 14, 2018 · 10 comments
Closed

Don't modify whitespace. #295

naught101 opened this issue Feb 14, 2018 · 10 comments

Comments

@naught101
Copy link

naught101 commented Feb 14, 2018

I'm using Orzly 1.6.2, and syncing notes with syncthing to my local machine, where I edit org files with vim. Mostly this works pretty well, but I prefer to use white space to separate main sections in org files, to make them easier to read in vim.

However, when files are modified in in Orgzly, it adds empty lines (particularly around contents of notes), and removes empty lines (particularly above top-level notes). This is particularly annoying, because it makes sync conflicts much more annoying to merge (e.g. when I edit an org file on my phone and laptop at the same time, syncthing keeps a copy of both, with one marked as a sync conflict, so that the conflict can be manually merged).

Orgzly should avoid modifying whitespace when editing existing notes (e.g. stick with what ever is already there). Adding whitespace when creating new notes is ok, but personally I'd prefer if contents of notes were not surrounded by empty lines (especially not empty lines above the contents).

@naught101
Copy link
Author

Further on the whitespace front: it would be good if tags added to the end of the first line of a note/TODO were left there, rather than being added on their own line.

Personally, I'd prefer if Orgzly tagged in this way by default, but I understand that's just a personal preference. But it would be good if tags added in other apps were not modified unless explicitly modified in Orgzly.

@keithcrone
Copy link

keithcrone commented Feb 15, 2018 via email

@naught101
Copy link
Author

Ah, so there is, hidden under the sync settings.

Hrm. it's still not optimal though. I still think it would be good to have a default behaviour or setting that prevents orgzly from reformatting notes that it hasn't modified. But I guess that might be difficult..

Options that would help me get around that (because it would allow me to set Orgzly to format how I want it):

  • Setting for empty line before headings of a given level (e.g. I select 2, and it adds an empty line before each level 1 and level 2 note)
  • Even with "separate header and content" turned off, there is a space after the content. Would be good to have the option to disable that (I don't need space between content and the next level 3 note, for instance).
  • I would prefer if the content was indented to the level of the text of the note (so, for a level 3 note, indent should be 4 spaces).

@naught101
Copy link
Author

I guess the "sync when repository is modified" feature will also help avoid the syncthing conflicts I'm seeing, once it's implemented..

@naught101
Copy link
Author

And this #287

@nevenz
Copy link
Member

nevenz commented Feb 16, 2018

See #190, #264 and http://www.orgzly.com/help#org-mode

Further on the whitespace front: it would be good if tags added to the end of the first line of a note/TODO were left there, rather than being added on their own line.

This shouldn't be happening, can you post an example of what you're seeing?

@naught101
Copy link
Author

It didn't seem to do it the last few times I've tried. Possibly I'm getting confused by something vim-orgmode did...

@nevenz
Copy link
Member

nevenz commented Feb 16, 2018

Perhaps they just line-wrapped?

I'll close this as a duplicate of issues I mentioned. We can add to them if they need more info.

@naught101
Copy link
Author

Fair enough. Sorry for the noise, and thanks for all of your hard work.

FWIW, I think the first bullet point above (custom white space above notes of level <=n) would be super useful for readability on plaintext systems.. Is it worth putting in a new, cleaner issue for that?

@nevenz
Copy link
Member

nevenz commented Feb 16, 2018

FWIW, I think the first bullet point above (custom white space above notes of level <=n) would be super useful for readability on plaintext systems.. Is it worth putting in a new, cleaner issue for that?

I guess, though it's pretty specific and those options are getting a little out of control. But since keeping all the white-space intact is more trickier then it sounds, it should be fine short-term.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants