• tguillemin

    @jsamlarose47

    I have the feeling, after using your VERY useful workflow, that we answer 2 different cases :

    • my solution : if the contents of a fold contain a specific pattern (and there can be as many different patterns as there are different words in the text), then keep open (unfolded) the fold with its contents
    • your solution : if a pattern is found, and this pattern is bound to be more specific (@something, or as I tried #\d{3}, etc...), keep the fold unfolded with its contents wether the pattern is found in the header or found in the contents of the fold

    My conclusion - and I am very grateful for your answer - is that these 2 solutions are complementary, for my specific uses anyway.

    Thanks again for your help

    posted in Editorial read more
  • tguillemin

    Very glad I could be of any help to you..

    But, you know, I think both of us should above all thank omz for this very remarkable software…

    Thanks again for your answer

    posted in Editorial read more
  • tguillemin

    First of all, thanks for your answer.
    I had indeed moved on, because I had found a solution suited for my needs :

    http://www.editorial-workflows.com/workflow/5892414547951616/3rPK8OHQ7KY

    As you can see (I hope you will be able to read it : it is the first time I share a workflow), this contraption :

    • is in French
    • includes a Critic Markup Title hypothesis (you may set it aside)

    I suppose you can turn this in a real Rube Goldberg by introducing the choice of 2 patterns, which would allow to choose :

    • A
    • NOT A
    • A OR B
    • A AND B
    • A AND NOT B
    • NOT (A OR B)
    • NOT (A AND B)

    but then I decided to Keep It Simple.

    Thanks again

    posted in Editorial read more
  • tguillemin

    I encounter 2 different placeholder labels' position :

    • in lieu of the folded lines, i.e. under the "folding" header
    • at the end of the "folding" header

    This second type seems to have 2 advantages : it is more compact, and it allows to move up/down the block (header and folded lines) in one step.

    Is it possible to choose between those 2 configurations ?

    Thanks

    posted in Editorial read more
  • tguillemin

    @ccc said:

    lines = '\n'.join(line[:1].title() + line[1:] for line in lines.splitlines()) + '\n'

    I had not tried it with blank lines (in my file, it does not occur)
    Nevertheless, I tried your solution - successfully - after inserting those blank lines.

    Thank you. That will most certainly be useful some day…!

    posted in Editorial read more
  • tguillemin

    It woks nicely
    Thank you very much, and thanks again for this app.

    posted in Editorial read more
  • tguillemin

    I want to capitalize the first letter of each line in a text. So, I came up with the following Find/Replace (Regular Expression)

    Find : ^([a-z])

    Replace with : \U$1

    This works in Regex101 (Python flavor), but not in Editorial (I get a capital U at the beginning of each line starting with a lower case character)

    Where did I go wrong ?

    Thanks in advance

    posted in Editorial read more
  • tguillemin

    Thank you very much for your answer.

    It works, of course, beautifully.

    Thanks again

    posted in Editorial read more
  • tguillemin

    This is, of course , inspired by the question "List of workflows"
    [https://forum.omz-software.com/topic/3994/list-of-workflows](link url)

    I wondered if it would be possible to obtain the list of all sub-workflows in the different main workflows, e.g. :

    workflowfoo:subworkflowbar
    workflowfoo:subworkflowbaz

    Although this would help me keeping organized (some workflows are used as sub-workflows in more than one other workflow), this is, alas, far beyond my competences…

    Thanks in advance

    posted in Editorial read more
  • tguillemin

    I want to build a workflow to fold/unfold not lines, but specific headers and their contents, and I do not know how to proceed.(I suppose iwhat action ? what Regex ?). Of course I know how to do that manually…

    I have a text, e.g. :

    #Chapter one (@tag1, @tag2)
    
    some text
    some other text
    
    #Chapter two (@tag2, @tag3)
    
    foo
    ber
    baz
    
    #Chapter three (@tag1, @tag3)
    
    London
    Paris
    Berlin
    
    #Chapter four (@tag2, @tag4)
    
    something
    anything
    

    I want to select the, e.g. @tag1 headers and unfold these and these only, so as to have :

    #Chapter one (@tag1, @tag2)
    
    some text
    some other text
    
    [number of hidden words]
    
    #Chapter three (@tag1, @tag3)
    
    London
    Paris
    Berlin
    
    [number of hidden words]
    

    How should I proceed ?

    Thanks in advance

    posted in Editorial read more

Internal error.

Oops! Looks like something went wrong!