About 50 results
Open links in new tab
  1. How to run only selected lines of a shell script? - Ask Ubuntu

    Sep 4, 2024 · On Windows it's possible to create a *.ps1 (PowerShell) file where you can write one command per line or initialize variables etc. You then open it with VSCode and select the lines that …

  2. bash - Why does my powershell script run with "pwsh" but doesn't with ...

    Jan 4, 2024 · The scripts no longer work with crontab. Specifically, it doesn't retrieve the data from Azure anymore. I know this isn't an Azure issue because I can run the script fine manually in the …

  3. wsl -e cannot run a script that I can run when wsl has been executed

    Sep 28, 2023 · "bash is active and on normal wsl it isn't" - Actually, it is. Without the -e, WSL invokes the default user shell and passes the remaining command-line to it using -c. You can demonstrate this …

  4. Converting PowerShell (.ps1) script to Windows Executable (.EXE) on ...

    Jun 10, 2023 · In this particular section of my project, I need to generate executable files (exe) from dynamic PowerShell (ps1) scripts at runtime. These exe files will then be downloaded onto my …

  5. windows - Can I run PowerShell on Ubuntu? - Ask Ubuntu

    Aug 3, 2014 · I have been assigned a project to be done in Windows PowerShell. I am familiar with shell scripting but it's a new technology. I was told that its similar to shell except few syntax changes. I hav...

  6. Is it possible to run a WSL app in the background?

    Oct 17, 2022 · Following the previous example: With Systemd still disabled, from PowerShell, wsl --shutdown Start Ubuntu (e.g. wsl ~) Run nohup sleep 100000 & Hit Enter one extra time to dismiss …

  7. conda activate not working in a bash file - Ask Ubuntu

    Sep 5, 2019 · I am trying to write a script with the name myscrpt.sh, so when I run it it automatically creates a virtual env and activate it using conda. My conda version is 4.7.1.

  8. How to make a file (e.g. a .sh script) executable, so it can be run ...

    Dec 16, 2012 · The OP asked "how to make script.sh executable. While you can do that, the original intent of the .sh suffix was to allow you to have a "source" and and "object" file.

  9. How do I fix "$'\r': command not found" errors running Bash scripts in ...

    Oct 20, 2017 · This works. I was using VSCode and had a shell script that executes some rsync and ssh command, and ran into this issue. I installed dos2unix inside WSL like Chaim said, and executed …

  10. Getting error while executing PowerShell cmdlet on ubuntu machine

    May 12, 2022 · I was currently running PowerShell on ubuntu machine with the help of VS code by importing packages. The commands which I used are: sudo apt update; sudo apt-get install …