Bottom Page

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 f-string in command line arguments
#1
i am starting the design of a command i have previously written in C now to be in Python3. this command takes input from stdin and executes a command given in the command line arguments with a certain character being substituted with a line from stdin, repeating for each line in stdin. but, i want to make some changes in the new Python3 version. to start with, i want to support the use of f-strings on the given command argument. what i am wondering is how i might do that. the code will be getting an ordinary string from sys.argv and will need to handle it like it were an f-string. i have not even started the design, yet, or even the code. any suggestions on the direction to go with the f-strings part?

i left out part of the description of the command. it uses one special argument ... the maximum number of parallel processes running commands. if that number is 1 then, obviously, it just does one at a time. if a number less than 1 is given, it outputs the commands it would have run, in the order given.
What do you call someone who speaks three languages? Trilingual. Two languages? Bilingual. One language? American.
Quote

Top Page

Possibly Related Threads...
Thread Author Replies Views Last Post
  my own command line option parser Skaperen 0 152 Mar-27-2020, 04:14 AM
Last Post: Skaperen
  i need a module for more involved command line parsing Skaperen 21 1,084 Sep-04-2019, 02:18 AM
Last Post: Skaperen
  python command (2 and 3) ignores extra -c arguments Skaperen 4 329 Aug-27-2019, 12:34 AM
Last Post: Skaperen

Forum Jump:


Users browsing this thread: 1 Guest(s)