Bug 34915 - how-to.pl/tt blocks translation script
Summary: how-to.pl/tt blocks translation script
Status: RESOLVED MOVED
Alias: None
Product: Koha
Classification: Unclassified
Component: Command-line Utilities (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-09-26 13:32 UTC by Caroline Cyr La Rose
Modified: 2023-09-29 13:50 UTC (History)
2 users (show)

See Also:
GIT URL:
Initiative type: ---
Sponsorship status: ---
Comma delimited list of Sponsors:
Crowdfunding goal: 0
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Screenshot of the error in a terminal window (102.81 KB, image/png)
2023-09-26 13:32 UTC, Caroline Cyr La Rose
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Caroline Cyr La Rose 2023-09-26 13:32:26 UTC
Created attachment 156223 [details]
Screenshot of the error in a terminal window

I'm putting this here, I don't know if this is a "just me" problem or if it's a larger one. I've only recently started using KTD so I might not be using it correctly. I'm more used to using the git installation.

When I do `ktd up` it adds "how-to" files in my koha git directory. When I do `ktd down` those files are not removed. Normally, I don't think I would mind, but the translation update script doesn't like those files at all.

To recreate:
1. ktd up
2. ktd down
3. In the git directory, run `gulp po:update --lang fr-CA`
--> Error

[09:20:40] 'po_extract_messages' errored after 2.17 s
[09:20:40] Error: ENOENT: no such file or directory, stat '[...]how-to.pl'
[09:20:40] 'po:update' errored after 2.18 s


I added a screenshot of what it looks like in my terminal.
Comment 1 Jonathan Druart 2023-09-26 17:12:12 UTC
Hum, sorry but I don't have a good solution here.

I've tried hard to exclude this file from the script, but failed...
Comment 2 Caroline Cyr La Rose 2023-09-26 18:12:43 UTC
I'll make myself an alias to run after `ktd down`.

So should I close this bug, or you want to keep it open?
Comment 3 Caroline Cyr La Rose 2023-09-26 18:39:51 UTC
in case anyone needs it, I added this to ~/.bash_aliases

alias rmhowto='rm -rf $KOHA_PATH/how-to.pl && rm -rf $KOHA_PATH/koha-tmpl/intranet-tmpl/prog/en/modules/how-to.tt'

I don't know if it would work in any environment, but this works for me. To be run after `ktd down`
Comment 4 Jonathan Druart 2023-09-27 06:35:58 UTC
This may be a solution: https://stackoverflow.com/questions/41451159/how-to-execute-a-script-when-i-terminate-a-docker-container

And it will need to be done in ktd. I would open an issue there.