On Sun, Jul 14, 2019 at 11:28:28PM -0600, Joel Kulesza wrote:
> LyX Developers (Jürgen in particular):
> 
> A few questions on the Insert -> Field capability with respect to version
> control:
> 
>    1. When git hashes (i.e. VCS Revisions) are entered, I see that they are
>    updated when the underlying revision is updated.  This generally delights
>    me.  However, what governs this update logic timing (when the document is
>    opened, at some interval, etc.)?  Is there an indication to the user that
>    this part of the document has changed?  If not, should there be?

Without looking at the code IIRC it updates at each document (re)load (that
includes git commits via lyx gui).

>    2. Can one add/save custom commands for fields?  For example, I want to
>    insert an abbreviated git hash (e.g., `git rev-parse --short HEAD`).  If
>    so, where can I enter this?  Sorry if I missed the right spot in my search.

You don't want to allow this, because of other users sending you lyx files
with fields containing rm -rf / commands...
You might be able to do that with your own external template though.
Alternatively I think we would still accept patch for 2.4 with a new custom
field containing short hash (named like "short revision" or similar).

>    3. I was able to induce an error that popped up a dialog with a cryptic
>    error rather than, as I imagine is intended, the error given at the console
>    "Error: Revision control error".  See attached.  Is this expected?  I did
>    this by using a git repository that doesn't have any tags.  Please let me
>    know if you'd like more detail to reproduce and/or if I should file a Trac
>    issue.

This might be our fault and steps to reproduce could help.

Pavel

Reply via email to