Repository navigation
template: fix category and binary name prompts ignoring the answer - #3075
Merged
Merged
Conversation
_read_e takes no arguments: it prints whatever is in $prompt and stores the answer in $results. Commit 21a7b3b turned three "read -r -p" calls into "_read_e PROMPT VAR", which shows the previous prompt and never sets VAR. 294e41d fixed the template-type prompt by switching it to _read_rep; the category prompt and the binary name prompt (AppImages built on-the-fly) were still on _read_e. Because of that, every script made with "am -t" got Categories=Utility whatever category you picked, a custom binary name was never applied, and the category step showed "NAME OF THE APP" again instead of "CHOOSE A CATEGORY". Use _read_rep for both, like 294e41d did. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Owner
|
Thanks, and welcome on board @sagarrsharmaa |
Contributor
Author
|
thanks @ivan-hc ✨ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two prompts in
am -t/appman -tignore what you type:Categories=Utility, whatever number you pick. This step also shows "NAME OF THE APP" again instead of the category question."$APP"._read_edoesn't take arguments: it prints$promptand puts the answer in$results. Commit 21a7b3b changed threeread -r -p "..." VARlines to_read_e "..." VAR, and 294e41d already fixed one of them (the template-type prompt) by switching it to_read_rep. These are the other two, with the same one-word change.How I tested it: ran
appman -tin a throwaway Debian container with scripted answers (-tonly writes the script file, nothing gets installed).Categories=Development;(wasUtility)mybin→sh -s -- ./* mybin(was"$APP")Utilityand"$APP").bash -nis fine, shellcheck reports nothing new, andregress/test-am-template-similar.shpasses.