-
Notifications
You must be signed in to change notification settings - Fork 33
Description
There is one thing that has been bothering me for a while, and I don't know if it's an issue with documentation or if it is really how it is supposed to work.
So the command pot create has a parameter -b where docs say -b base : the base pot. Ok, so let's create a base pot, right.
pot create-base -r 14.0 -b mybase14
then
pot ls -b
shows
bases: mybase14
It all works up to this point; the base pot is created and updated with the latest patches. Then I continue with creating new pot using a base pot
pot create -p mypot -b mybase14 -t single but I get the error
###> mybase14 is not a valid release
Going through the code I found
Lines 614 to 625 in 9ac5a5f
| else | |
| if [ -z "$_base" ]; then | |
| _error "at least one of -b and -P has to be used" | |
| create-help | |
| ${EXIT} 1 | |
| fi | |
| if ! _is_valid_release "$_base" ; then | |
| _error "$_base is not a valid release" | |
| create-help | |
| ${EXIT} 1 | |
| fi | |
| fi |
And function _is_valid_release
Lines 919 to 926 in 9ac5a5f
| _rel="$1" | |
| _releases="$( _get_valid_releases )" | |
| # shellcheck disable=SC2086 | |
| if _is_in_list "$_rel" $_releases ; then | |
| return 0 # true | |
| else | |
| return 1 # false | |
| fi |
That checks if my base pot is actually a release itself. Which is not. Then I thought ok let's go and use -P as this is documented as -P pot : the pot to be used as reference
pot create -p mypot -P mybase14 -t single but I get the error
###> pot mybase14 not found
From the code, it's obvious since the base pot is not a regular pot.
I would like to fix the doc in a way that can guide me through this, but something isn't right here, or maybe I'm missing something. I can see from the code that both -b and -P can be used simultaneously. But I don't know how the base and this pot should be set up for this to work.
The workaround, for now, is just to create pot from release and use an updated flavour in combination with other flavours. And this takes a bit more time to always do extract and update before anything else can be created.