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

command 'superbol-free reformat to-free FILES.cob' #201

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

lefessan
Copy link
Member

@lefessan lefessan commented Mar 7, 2024

Translate files from fixed to free format

In case it can be useful to somebody else...

Translate files from fixed to free format
@nberth
Copy link
Collaborator

nberth commented Mar 7, 2024

If you were using cobol_preproc you'd get proper right-padding of alphanumerics that are broken across several lines, along with support for change-of-format compiler directives (that can often be seen at the top of COBOL source files).

Anyways, given the stated restriction on fixed format, I'd suggest to rename the command into "reformat fixed-to-free".

@GitMensch
Copy link

@lefessan If you add that - a reverse command would be much more useful, as many peprocessors only handle fixed-form reference-format.

@nberth: I think you should be able to package a native binary of cobol_preproc with the LSP which allows an extension command (or multiple ones) to trigger that.

* call indenter at the end of formatting
* parse compiler directives to change the format in the middle of source files
* prepare for free-2-fixed conversion
@GitMensch
Copy link

friendly ping @nberth @lefessan

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

Successfully merging this pull request may close these issues.

3 participants