Loss of csv file sync when saving #9

Open
opened 2021-02-10 03:05:22 +00:00 by igoralmeida · 1 comment
igoralmeida commented 2021-02-10 03:05:22 +00:00 (Migrated from github.com)

Hey tecosaur, I'm trying out org-pandoc-import to manage some csvs, and there is an important papercut I'd like to address when transient mode is enabled:

  1. I add a new line to the org table (point is <|>)
...other rows...
| last | row |
|  abc | defgh<|> |
  1. I press TAB to align everything nicely
...other rows...
| last |   row |
|  abc | defgh |
|<|>   |       | 
  1. Leave insert state and delete the final line
...other rows...
| last |   row |
|  abc | defgh |
<|>
  1. Try to save the file and get an error message
    user-error: Point is not inside a table

Now at this point the CSV and org files are no longer in sync. If I remember, I will go back to the table and save the file again, only to get (No changes need to be saved), so I need to make the file dirty again, get it back to how it looks on step 3 there, move my cursor to inside the table, and then save.

As a workaround, I could delete two lines on step 3, which would get me back to the end of the table and avoid the problem in step 4, but it would be better to make the saving function a bit smarter. How can I achieve that?

Hey tecosaur, I'm trying out org-pandoc-import to manage some csvs, and there is an important papercut I'd like to address when transient mode is enabled: 1. I add a new line to the org table (point is `<|>`) ``` ...other rows... | last | row | | abc | defgh<|> | ``` 2. I press TAB to align everything nicely ``` ...other rows... | last | row | | abc | defgh | |<|> | | ``` 3. Leave insert state and delete the final line ``` ...other rows... | last | row | | abc | defgh | <|> ``` 4. Try to save the file and get an error message `user-error: Point is not inside a table` Now at this point the CSV and org files are no longer in sync. If I remember, I will go back to the table and save the file again, only to get `(No changes need to be saved)`, so I need to make the file dirty again, get it back to how it looks on step 3 there, move my cursor to inside the table, and *then* save. As a workaround, I *could* delete two lines on step 3, which would get me back to the end of the table and avoid the problem in step 4, but it would be better to make the saving function a bit smarter. How can I achieve that?
tecosaur commented 2021-02-10 03:12:54 +00:00 (Migrated from github.com)

Mmmm. This definitely feels like it needs changing. This might take a bit (I'll try to address issue 8 first) but I have an idea for solving this.

Mmmm. This definitely feels like it needs changing. This might take a bit (I'll try to address issue 8 first) but I have an idea for solving this.
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: tec/org-pandoc-import#9
No description provided.