$EDITOR environment variable won't set The 2019 Stack Overflow Developer Survey Results Are InHow do you set an environment variable?Environment variable set but not respectedIs there anyway to set a readonly environment variable?How to set environment variable for BACI compiler and interpreter?Where does the TERM environment variable default get set?Set environment variable $PATH globally on Ubuntu 14.04Environment variable specifying preferred terminalSet persistent environment variable for all usersSet environment variable for subshellSet environment variable for all login scenarios

The phrase "to the numbers born"?

Is it possible for absolutely everyone to attain enlightenment?

Is it okay to consider publishing in my first year of PhD?

Does HR tell a hiring manager about salary negotiations?

If I score a critical hit on an 18 or higher, what are my chances of getting a critical hit if I roll 3d20?

Can we generate random numbers using irrational numbers like π and e?

Relationship between Gromov-Witten and Taubes' Gromov invariant

Why are there uneven bright areas in this photo of black hole?

How come people say “Would of”?

Can a flute soloist sit?

Dropping list elements from nested list after evaluation

"as much details as you can remember"

Can a rogue use sneak attack with weapons that have the thrown property even if they are not thrown?

Star Trek - X-shaped Item on Regula/Orbital Office Starbases

Output the Arecibo Message

Table Fragmentation

Did Scotland spend $250,000 for the slogan "Welcome to Scotland"?

What do these terms in Caesar's Gallic wars mean?

If I can cast sorceries at instant speed, can I use sorcery-speed activated abilities at instant speed?

How to obtain a position of last non-zero element

What does Linus Torvalds mean when he says that Git "never ever" tracks a file?

Get name of standard action overriden in Visualforce contorller

Why does the nucleus not repel itself?

Match Roman Numerals



$EDITOR environment variable won't set



The 2019 Stack Overflow Developer Survey Results Are InHow do you set an environment variable?Environment variable set but not respectedIs there anyway to set a readonly environment variable?How to set environment variable for BACI compiler and interpreter?Where does the TERM environment variable default get set?Set environment variable $PATH globally on Ubuntu 14.04Environment variable specifying preferred terminalSet persistent environment variable for all usersSet environment variable for subshellSet environment variable for all login scenarios



.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








1















Whenever I attempt to set the EDITOR environment variable, a subsequent check reveals no value has been set.



I was attempting to edit the crontab:



sudo crontab -e -u mycooluser


which returns:



no crontab for mycooluser - using an empty one
Error opening terminal: unknown.
crontab: "/usr/bin/sensible-editor" exited with status 1


I then found this post:
Setup a cronjob from commandline which suggested I change the editor used.



So I tried (including variations):



export EDITOR="/bin/nano"
export EDITOR="usr/bin/nano"
export EDITOR=nano


and when I execute (per this link How do I find and set my $EDITOR environment variable?):



echo $EDITOR


OR



printenv | grep EDITOR


I get nothing, a quick printenv check also confirms that no EDITOR variable exists in the list. To be clear, by 'nothing' I mean that on the echo $EDITOR it prints a blank line and for printenv | grep EDITOR nothing is printed.



Any idea why the variable isn't being set or why I can't seem to change it?



System:
Ubuntu 18.04.1, Using Terminal in Webmin










share|improve this question







New contributor




Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • You do not get a message like EDITOR: readonly variable when attempting to set the value, correct?

    – Jeff Schaller
    4 hours ago











  • Correct, I do not, when I set the value, it acts as though it was executed with no other messages displayed.

    – Josh Whitlow
    4 hours ago












  • What happens if you try EDITOR="/bin/nano" crontab -e?

    – Panki
    3 hours ago











  • It returns the following: Error opening terminal: unknown. crontab: "/bin/nano" exited with status 1

    – Josh Whitlow
    3 hours ago

















1















Whenever I attempt to set the EDITOR environment variable, a subsequent check reveals no value has been set.



I was attempting to edit the crontab:



sudo crontab -e -u mycooluser


which returns:



no crontab for mycooluser - using an empty one
Error opening terminal: unknown.
crontab: "/usr/bin/sensible-editor" exited with status 1


I then found this post:
Setup a cronjob from commandline which suggested I change the editor used.



So I tried (including variations):



export EDITOR="/bin/nano"
export EDITOR="usr/bin/nano"
export EDITOR=nano


and when I execute (per this link How do I find and set my $EDITOR environment variable?):



echo $EDITOR


OR



printenv | grep EDITOR


I get nothing, a quick printenv check also confirms that no EDITOR variable exists in the list. To be clear, by 'nothing' I mean that on the echo $EDITOR it prints a blank line and for printenv | grep EDITOR nothing is printed.



Any idea why the variable isn't being set or why I can't seem to change it?



System:
Ubuntu 18.04.1, Using Terminal in Webmin










share|improve this question







New contributor




Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • You do not get a message like EDITOR: readonly variable when attempting to set the value, correct?

    – Jeff Schaller
    4 hours ago











  • Correct, I do not, when I set the value, it acts as though it was executed with no other messages displayed.

    – Josh Whitlow
    4 hours ago












  • What happens if you try EDITOR="/bin/nano" crontab -e?

    – Panki
    3 hours ago











  • It returns the following: Error opening terminal: unknown. crontab: "/bin/nano" exited with status 1

    – Josh Whitlow
    3 hours ago













1












1








1








Whenever I attempt to set the EDITOR environment variable, a subsequent check reveals no value has been set.



I was attempting to edit the crontab:



sudo crontab -e -u mycooluser


which returns:



no crontab for mycooluser - using an empty one
Error opening terminal: unknown.
crontab: "/usr/bin/sensible-editor" exited with status 1


I then found this post:
Setup a cronjob from commandline which suggested I change the editor used.



So I tried (including variations):



export EDITOR="/bin/nano"
export EDITOR="usr/bin/nano"
export EDITOR=nano


and when I execute (per this link How do I find and set my $EDITOR environment variable?):



echo $EDITOR


OR



printenv | grep EDITOR


I get nothing, a quick printenv check also confirms that no EDITOR variable exists in the list. To be clear, by 'nothing' I mean that on the echo $EDITOR it prints a blank line and for printenv | grep EDITOR nothing is printed.



Any idea why the variable isn't being set or why I can't seem to change it?



System:
Ubuntu 18.04.1, Using Terminal in Webmin










share|improve this question







New contributor




Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












Whenever I attempt to set the EDITOR environment variable, a subsequent check reveals no value has been set.



I was attempting to edit the crontab:



sudo crontab -e -u mycooluser


which returns:



no crontab for mycooluser - using an empty one
Error opening terminal: unknown.
crontab: "/usr/bin/sensible-editor" exited with status 1


I then found this post:
Setup a cronjob from commandline which suggested I change the editor used.



So I tried (including variations):



export EDITOR="/bin/nano"
export EDITOR="usr/bin/nano"
export EDITOR=nano


and when I execute (per this link How do I find and set my $EDITOR environment variable?):



echo $EDITOR


OR



printenv | grep EDITOR


I get nothing, a quick printenv check also confirms that no EDITOR variable exists in the list. To be clear, by 'nothing' I mean that on the echo $EDITOR it prints a blank line and for printenv | grep EDITOR nothing is printed.



Any idea why the variable isn't being set or why I can't seem to change it?



System:
Ubuntu 18.04.1, Using Terminal in Webmin







ubuntu terminal environment-variables webmin






share|improve this question







New contributor




Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question







New contributor




Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question






New contributor




Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked 4 hours ago









Josh WhitlowJosh Whitlow

1084




1084




New contributor




Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Josh Whitlow is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












  • You do not get a message like EDITOR: readonly variable when attempting to set the value, correct?

    – Jeff Schaller
    4 hours ago











  • Correct, I do not, when I set the value, it acts as though it was executed with no other messages displayed.

    – Josh Whitlow
    4 hours ago












  • What happens if you try EDITOR="/bin/nano" crontab -e?

    – Panki
    3 hours ago











  • It returns the following: Error opening terminal: unknown. crontab: "/bin/nano" exited with status 1

    – Josh Whitlow
    3 hours ago

















  • You do not get a message like EDITOR: readonly variable when attempting to set the value, correct?

    – Jeff Schaller
    4 hours ago











  • Correct, I do not, when I set the value, it acts as though it was executed with no other messages displayed.

    – Josh Whitlow
    4 hours ago












  • What happens if you try EDITOR="/bin/nano" crontab -e?

    – Panki
    3 hours ago











  • It returns the following: Error opening terminal: unknown. crontab: "/bin/nano" exited with status 1

    – Josh Whitlow
    3 hours ago
















You do not get a message like EDITOR: readonly variable when attempting to set the value, correct?

– Jeff Schaller
4 hours ago





You do not get a message like EDITOR: readonly variable when attempting to set the value, correct?

– Jeff Schaller
4 hours ago













Correct, I do not, when I set the value, it acts as though it was executed with no other messages displayed.

– Josh Whitlow
4 hours ago






Correct, I do not, when I set the value, it acts as though it was executed with no other messages displayed.

– Josh Whitlow
4 hours ago














What happens if you try EDITOR="/bin/nano" crontab -e?

– Panki
3 hours ago





What happens if you try EDITOR="/bin/nano" crontab -e?

– Panki
3 hours ago













It returns the following: Error opening terminal: unknown. crontab: "/bin/nano" exited with status 1

– Josh Whitlow
3 hours ago





It returns the following: Error opening terminal: unknown. crontab: "/bin/nano" exited with status 1

– Josh Whitlow
3 hours ago










1 Answer
1






active

oldest

votes


















5














You are using the so-called "popup shell". This is not a terminal. Nor is it in fact really a shell.



It's a piece of user interface fakery inside a WWW browser that executes shell commands separately from one another as individual transactions. There's no actual continually running shell to hold an environment variable. It is merely presented that way by the user interface in the WWW browser. The shell commands are run in a nonce process environment where no TERM environment variable has been set, and in a session with no controlling terminal. And even if it were set, there's no terminal emulator to handle the terminal I/O that full-screen programs like text editors use. Indeed, there is only provision for relaying output of the program back to the local machine; no input is sent in the other direction.



nano, pico, and emacs will complain about being unable to determine the terminal type and open the terminal. VIM and NeoVIM fall back to assumptions that simply do not hold in this case, and give the appearance of simply hanging. Not even line-mode editors like ex and ed will work as user input is simply not sent to the remote machine. (One possibly could drive ex non-interactively with its -c option.) Similarly, one cannot change passwords with the passwd command.



This has been a misunderstanding of the "popup shell" since at least 2016.



Further reading



  • "JedMeister" (2018-03-04). Interactive Terminal. Bug #1037. authentic-theme bugs.

  • Michael Hurt (2018-11-13). Error opening terminal: unknown. Bug #5214. Webmin bugs.

  • "7starsone" (2016-12-08). File Manager: Command line. Bug #566. authentic-theme bugs.





share|improve this answer

























  • I decided to SSH into the server and then run the crontab commands and it worked just fine, thanks for the info I had no idea! Even the history command doesn't show a single thing I've typed into the "popup shell".

    – Josh Whitlow
    3 hours ago











  • I think I heard you say that this was an opportunity for ed!

    – Jeff Schaller
    2 hours ago











Your Answer








StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);






Josh Whitlow is a new contributor. Be nice, and check out our Code of Conduct.









draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f511949%2feditor-environment-variable-wont-set%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









5














You are using the so-called "popup shell". This is not a terminal. Nor is it in fact really a shell.



It's a piece of user interface fakery inside a WWW browser that executes shell commands separately from one another as individual transactions. There's no actual continually running shell to hold an environment variable. It is merely presented that way by the user interface in the WWW browser. The shell commands are run in a nonce process environment where no TERM environment variable has been set, and in a session with no controlling terminal. And even if it were set, there's no terminal emulator to handle the terminal I/O that full-screen programs like text editors use. Indeed, there is only provision for relaying output of the program back to the local machine; no input is sent in the other direction.



nano, pico, and emacs will complain about being unable to determine the terminal type and open the terminal. VIM and NeoVIM fall back to assumptions that simply do not hold in this case, and give the appearance of simply hanging. Not even line-mode editors like ex and ed will work as user input is simply not sent to the remote machine. (One possibly could drive ex non-interactively with its -c option.) Similarly, one cannot change passwords with the passwd command.



This has been a misunderstanding of the "popup shell" since at least 2016.



Further reading



  • "JedMeister" (2018-03-04). Interactive Terminal. Bug #1037. authentic-theme bugs.

  • Michael Hurt (2018-11-13). Error opening terminal: unknown. Bug #5214. Webmin bugs.

  • "7starsone" (2016-12-08). File Manager: Command line. Bug #566. authentic-theme bugs.





share|improve this answer

























  • I decided to SSH into the server and then run the crontab commands and it worked just fine, thanks for the info I had no idea! Even the history command doesn't show a single thing I've typed into the "popup shell".

    – Josh Whitlow
    3 hours ago











  • I think I heard you say that this was an opportunity for ed!

    – Jeff Schaller
    2 hours ago















5














You are using the so-called "popup shell". This is not a terminal. Nor is it in fact really a shell.



It's a piece of user interface fakery inside a WWW browser that executes shell commands separately from one another as individual transactions. There's no actual continually running shell to hold an environment variable. It is merely presented that way by the user interface in the WWW browser. The shell commands are run in a nonce process environment where no TERM environment variable has been set, and in a session with no controlling terminal. And even if it were set, there's no terminal emulator to handle the terminal I/O that full-screen programs like text editors use. Indeed, there is only provision for relaying output of the program back to the local machine; no input is sent in the other direction.



nano, pico, and emacs will complain about being unable to determine the terminal type and open the terminal. VIM and NeoVIM fall back to assumptions that simply do not hold in this case, and give the appearance of simply hanging. Not even line-mode editors like ex and ed will work as user input is simply not sent to the remote machine. (One possibly could drive ex non-interactively with its -c option.) Similarly, one cannot change passwords with the passwd command.



This has been a misunderstanding of the "popup shell" since at least 2016.



Further reading



  • "JedMeister" (2018-03-04). Interactive Terminal. Bug #1037. authentic-theme bugs.

  • Michael Hurt (2018-11-13). Error opening terminal: unknown. Bug #5214. Webmin bugs.

  • "7starsone" (2016-12-08). File Manager: Command line. Bug #566. authentic-theme bugs.





share|improve this answer

























  • I decided to SSH into the server and then run the crontab commands and it worked just fine, thanks for the info I had no idea! Even the history command doesn't show a single thing I've typed into the "popup shell".

    – Josh Whitlow
    3 hours ago











  • I think I heard you say that this was an opportunity for ed!

    – Jeff Schaller
    2 hours ago













5












5








5







You are using the so-called "popup shell". This is not a terminal. Nor is it in fact really a shell.



It's a piece of user interface fakery inside a WWW browser that executes shell commands separately from one another as individual transactions. There's no actual continually running shell to hold an environment variable. It is merely presented that way by the user interface in the WWW browser. The shell commands are run in a nonce process environment where no TERM environment variable has been set, and in a session with no controlling terminal. And even if it were set, there's no terminal emulator to handle the terminal I/O that full-screen programs like text editors use. Indeed, there is only provision for relaying output of the program back to the local machine; no input is sent in the other direction.



nano, pico, and emacs will complain about being unable to determine the terminal type and open the terminal. VIM and NeoVIM fall back to assumptions that simply do not hold in this case, and give the appearance of simply hanging. Not even line-mode editors like ex and ed will work as user input is simply not sent to the remote machine. (One possibly could drive ex non-interactively with its -c option.) Similarly, one cannot change passwords with the passwd command.



This has been a misunderstanding of the "popup shell" since at least 2016.



Further reading



  • "JedMeister" (2018-03-04). Interactive Terminal. Bug #1037. authentic-theme bugs.

  • Michael Hurt (2018-11-13). Error opening terminal: unknown. Bug #5214. Webmin bugs.

  • "7starsone" (2016-12-08). File Manager: Command line. Bug #566. authentic-theme bugs.





share|improve this answer















You are using the so-called "popup shell". This is not a terminal. Nor is it in fact really a shell.



It's a piece of user interface fakery inside a WWW browser that executes shell commands separately from one another as individual transactions. There's no actual continually running shell to hold an environment variable. It is merely presented that way by the user interface in the WWW browser. The shell commands are run in a nonce process environment where no TERM environment variable has been set, and in a session with no controlling terminal. And even if it were set, there's no terminal emulator to handle the terminal I/O that full-screen programs like text editors use. Indeed, there is only provision for relaying output of the program back to the local machine; no input is sent in the other direction.



nano, pico, and emacs will complain about being unable to determine the terminal type and open the terminal. VIM and NeoVIM fall back to assumptions that simply do not hold in this case, and give the appearance of simply hanging. Not even line-mode editors like ex and ed will work as user input is simply not sent to the remote machine. (One possibly could drive ex non-interactively with its -c option.) Similarly, one cannot change passwords with the passwd command.



This has been a misunderstanding of the "popup shell" since at least 2016.



Further reading



  • "JedMeister" (2018-03-04). Interactive Terminal. Bug #1037. authentic-theme bugs.

  • Michael Hurt (2018-11-13). Error opening terminal: unknown. Bug #5214. Webmin bugs.

  • "7starsone" (2016-12-08). File Manager: Command line. Bug #566. authentic-theme bugs.






share|improve this answer














share|improve this answer



share|improve this answer








edited 2 hours ago

























answered 3 hours ago









JdeBPJdeBP

38k478183




38k478183












  • I decided to SSH into the server and then run the crontab commands and it worked just fine, thanks for the info I had no idea! Even the history command doesn't show a single thing I've typed into the "popup shell".

    – Josh Whitlow
    3 hours ago











  • I think I heard you say that this was an opportunity for ed!

    – Jeff Schaller
    2 hours ago

















  • I decided to SSH into the server and then run the crontab commands and it worked just fine, thanks for the info I had no idea! Even the history command doesn't show a single thing I've typed into the "popup shell".

    – Josh Whitlow
    3 hours ago











  • I think I heard you say that this was an opportunity for ed!

    – Jeff Schaller
    2 hours ago
















I decided to SSH into the server and then run the crontab commands and it worked just fine, thanks for the info I had no idea! Even the history command doesn't show a single thing I've typed into the "popup shell".

– Josh Whitlow
3 hours ago





I decided to SSH into the server and then run the crontab commands and it worked just fine, thanks for the info I had no idea! Even the history command doesn't show a single thing I've typed into the "popup shell".

– Josh Whitlow
3 hours ago













I think I heard you say that this was an opportunity for ed!

– Jeff Schaller
2 hours ago





I think I heard you say that this was an opportunity for ed!

– Jeff Schaller
2 hours ago










Josh Whitlow is a new contributor. Be nice, and check out our Code of Conduct.









draft saved

draft discarded


















Josh Whitlow is a new contributor. Be nice, and check out our Code of Conduct.












Josh Whitlow is a new contributor. Be nice, and check out our Code of Conduct.











Josh Whitlow is a new contributor. Be nice, and check out our Code of Conduct.














Thanks for contributing an answer to Unix & Linux Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f511949%2feditor-environment-variable-wont-set%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Era Viking Índice Início da Era Viquingue | Cotidiano | Sociedade | Língua | Religião | A arte | As primeiras cidades | As viagens dos viquingues | Viquingues do Oeste e Leste | Fim da Era Viquingue | Fontes históricas | Referências Bibliografia | Ligações externas | Menu de navegação«Sverige då!»«Handel I vikingetid»«O que é Nórdico Antigo»Mito, magia e religião na volsunga saga Um olhar sobre a trajetória mítica do herói sigurd«Bonden var den verklige vikingen»«Vikingatiden»«Vikingatiden»«Vinland»«Guerreiras de Óðinn: As Valkyrjor na Mitologia Viking»1519-9053«Esculpindo símbolos e seres: A arte viking em pedras rúnicas»1679-9313Historia - Tema: VikingarnaAventura e Magia no Mundo das Sagas IslandesasEra Vikinge

What's the metal clinking sound at the end of credits in Avengers: Endgame?What makes Thanos so strong in Avengers: Endgame?Who is the character that appears at the end of Endgame?What happens to Mjolnir (Thor's hammer) at the end of Endgame?The People's Ages in Avengers: EndgameWhat did Nebula do in Avengers: Endgame?Messing with time in the Avengers: Endgame climaxAvengers: Endgame timelineWhat are the time-travel rules in Avengers Endgame?Why use this song in Avengers: Endgame Opening Logo Sequence?Peggy's age in Avengers Endgame

Which organization defines CJK Unified Ideographs? The Next CEO of Stack OverflowCharacters which have several different shapesHow useful are the kanji in reading Chinese?Can Chinese readers scan large amounts of text faster/more accurately than their alphabet-using counterparts?丼: why is “well” also “bowl of food”?What Does Unicode 8.0 Mean For Chinese?How are blanks indicated for placeholders in Chinese (like ???)Is there a dictionary of standard character variants?How to display CJK Extension F?How is it decided as to which character is used on the tech terminology?How does 子 come to mean 'midnight'?