andmarti1424 / sc-im

sc-im - Spreadsheet Calculator Improvised -- An ncurses spreadsheet program for terminal
Other
4.77k stars 201 forks source link

Backward compatibility with 0.8.2-1 #834

Closed asteri0 closed 11 months ago

asteri0 commented 11 months ago

Hello and congratulations for the great work on sc-im! While I appreciate the work to make sc-im handle xlsx's with multiple spreadsheets, I now face the following issue, as a user of multiple OS's: When I accessed my .sc files created with the latest version on Archlinux from a different computer which runs the WSL version of Ubuntu I get multiple "syntax error" prompts before accessing the file. That's because my WSL installation runs sc-im version 0.8.2-1, and I could not find a practical way to upgrade it to the latest version.
The solution I implemented was to downgrade my Archlinux sc-im to version 0.8.2-1 However, it would be very nice if you could provide a way to make the latest sc-im behave like the previous version, by passing a flag at command time ie. "sc-im --legacy", that I could make into a bash alias in .bashrc, while I wait for WSL to offer me the newer version of sc-im

andmarti1424 commented 11 months ago

Hello. I understand the problem. The thing is that sc-im format may have changed a lot since v0.8.2 (its from 2021). Try to find which lines cause the errors.. May be they are not related to the data but to the ui...

asteri0 commented 11 months ago

Hello. These are the lines which cause trouble on sc-im 0.8.3-1. At the beginning of every .sc file: 3a4,11

newsheet "Sheet1" movetosheet "Sheet1" offscr_sc_cols 0 offscr_sc_rows 685 nb_frozen_rows 2 nb_frozen_cols 0 nb_frozen_screenrows 2 nb_frozen_screencols 0

andmarti1424 commented 11 months ago

Seems v0.8.2 did not have multisheet support yet. If you remove those lines from the file, open and edit it on v0.8.2 and then open it on latest version.. it opens without error?

asteri0 commented 11 months ago

I can confirm that indeed this is the case