MiKTeX / docker-miktex

the Docker image for running MiKTeX
41 stars 28 forks source link

id : The term 'id' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. #12

Closed Jeff-Tian closed 4 years ago

Jeff-Tian commented 4 years ago

Run the example command on Windows get the error:

id : The term 'id' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.

Full command:

PS tex> docker run --rm -ti -v miktex:/miktext/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id
 -e MIKTEX_UID=$(id -u) miktex/miktex pdflatex .\fduthesis-template.tex
id : The term 'id' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:87
+ ... ex:/miktext/.miktex -v $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e  ...
+                                                                ~~
    + CategoryInfo          : ObjectNotFound: (id:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

id : The term 'id' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:110
+ ... $(pwd):/miktex/work -e MIKTEX_GID=$(id -g) -e MIKTEX_UID=$(id -u) mik ...
+                                                                ~~
    + CategoryInfo          : ObjectNotFound: (id:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException
nanmu42 commented 4 years ago

The example is under Linux enviroment.

Try getting rid of '-e id' part in Powershell.

Jeff-Tian commented 4 years ago

OK, thanks.