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

Rework setversion #40

Closed
josephwright opened this issue Dec 13, 2017 · 5 comments
Closed

Rework setversion #40

josephwright opened this issue Dec 13, 2017 · 5 comments
Assignees
Projects

Comments

@josephwright
Copy link
Member

Based on @wspr's excellent Lua code in #34, I realise that the current setversion customisation is not ideal. It should deal with a file handle not a line of text (reflects a TeX background!). At the same time, I remain unhappy about using -v for 'versionhere .. I think-tfor--tag` might be better ...

@FrankMittelbach
Copy link
Member

FrankMittelbach commented Dec 13, 2017

yes -v is rather unfortunate as this is universially known as "tell me your version". I like --tag not sure you need the short form.

@josephwright
Copy link
Member Author

Actually I probably should change how this works a bit: it would be better to require a tag name and go with

texlua build.lua tag [--date <date>] <name>

which is then pretty similar to e.g. Git's syntax.

@josephwright josephwright added this to To Do in Refactor Dec 21, 2017
@wspr
Copy link
Contributor

wspr commented Dec 28, 2017

I took a look at the code here and I actually don't mind the current approach.

With the manifest code it's important to pass around file handles because you're operating directly onto files as they're written. In the case of setversion the functionality seems more "contained" and simply dealing with a line of text encapsulates/simplifies what's going on.

It seems like using a file handle would add complexity for the user code — is there an advantage to doing this?

@josephwright
Copy link
Member Author

@wspr The current code is limited to a line-by-line approach: one might expect that some users want to do more complex manipulation.

As @FrankMittelbach notes, using -v has always been awkward.

@wspr
Copy link
Contributor

wspr commented Dec 30, 2017 via email

josephwright added a commit that referenced this issue Mar 5, 2018
Will clearly be needed for #40.
josephwright added a commit that referenced this issue Mar 5, 2018
This is the first key step to making a stand-alone script.

Note that one now needs to do "texlua l3build" or similar.

Various bits and pieces outstanding!
josephwright added a commit that referenced this issue Mar 6, 2018
This should allow both forms of usage, for the present,
but without having to reload files.
josephwright added a commit that referenced this issue Mar 6, 2018
We will still need to work on this, for example
once l3build can be run by name.
josephwright added a commit that referenced this issue Mar 6, 2018
Will clearly be needed for #40.
Refactor automation moved this from To Do to Done Mar 6, 2018
josephwright added a commit that referenced this issue Mar 6, 2018
Will clearly be needed for #40.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Refactor
  
Done
Development

No branches or pull requests

3 participants