windows-subsystem-for-linux

How to run program on ( ubuntu bash windows 10 ) from windows task scheduler

怎甘沉沦 提交于 2019-12-04 14:12:36
问题 I need to execute task every 5 minute in ubuntu bash and I like to use windows task scheduler. I don't know how to write a .bat file to start application in ubuntu bash. I tested these and did not work. c:\Windows\System32\bash.exe -l [program_name args] 回答1: can run command on ubuntu bash with add -c flag in args c:\Windows\System32\bash.exe -c <command> and write it in .bat file and then add to windows task scheduler. 来源: https://stackoverflow.com/questions/43818696/how-to-run-program-on

Installing Ruby on WSL (Windows Subsystem for Linux)

自闭症网瘾萝莉.ら 提交于 2019-12-04 12:17:36
问题 First off, sorry for my bad English. I'm trying to install Ruby 2.3.0 on my system with rbenv via Windows Subsystem for Linux aka Ubuntu on Windows 10. I followed this instruction (but not 100% exactly). but every time I try, It fails to build Ruby with this log. check struct members.. check libraries.... Use ActiveTcl libraries (if available). Search tclConfig.sh and tkConfig.sh.............................. Fail to find [tclConfig.sh, tkConfig.sh] Use X11 libraries (or use TK_XINCLUDES/TK

Connecting to the Windows Subsystem for Linux from Visual Studio 2017

孤者浪人 提交于 2019-12-04 10:27:08
I wish to debug a Linux C++ console application from VS2017, as in these tutorials: Writing And Debugging Linux C Applications From Visual Studio Using The Windows Subsystem For Linux targeting windows subsystem for Linux from visual studio I have installed gdbserver and openssh-server in my WSL Ubuntu 16.04 installation, and sshd is running, but I cannot connect from VS2017. When I try, I get the error 'Connectivity Failure. Please make sure the host name and port number are correct' . Both the host name and port number are correct as far as I am concerned. I know that WSL is still Beta, so I

Using Git in Windows Subsystem for Linux through IntelliJ

我是研究僧i 提交于 2019-12-04 07:46:09
问题 I'm trying to set Git executable in IntelliJ to be the git installed in Windows Subsystem for Linux, I tried a few different ways, but always got some sort of error. Today I installed to Creators Update (Version 1703), reinstalled WSL and tried again, here's what I did: I created a .bat script: @echo off C:\Windows\System32\bash.exe -c "git %*" So when running it: C:\Users\Limon\Desktop>bash.bat --version git version 2.7.4 So then I tried to set this bat at the git executable in IntelliJ: And

How to get `python` to run Python 3 in WSL bash?

▼魔方 西西 提交于 2019-12-04 07:41:18
When I type python into my bash shell (Windows Subsystem for Linux) in Windows 10 Home, I get the following error message: The program 'python' can be found in the following packages: * python-minimal * python3 Try: sudo apt install <selected package> I've tried installing python3 but am told it's already installed and up to date. I've tried uninstalling python-minimal but am told it's not installed (!) Why am I seeing two "competing" packages for Python? How can I fix the conflict and configure my WSL bash to run Python 3 from python ? python in linux world as a CLI command almost always

Windows Subsystem for Linux has missing Bash commands after changing directory to google drive file sync (GDFS)

纵然是瞬间 提交于 2019-12-04 05:04:26
问题 In the images below I have changed my directory to the mounted google drive file stream volume but i'm unable to use the ls command. Using Google Drive File Stream Version 28.1.48.2039 来源: https://stackoverflow.com/questions/49944731/windows-subsystem-for-linux-has-missing-bash-commands-after-changing-directory-t

Launch VS Code from WSL Bash

僤鯓⒐⒋嵵緔 提交于 2019-12-03 23:13:46
I have the Creators update installed. WSL is operational. I can execute most .exe files by simply calling notepad.exe But when it comes to VS Code.... I can't use the default code command or call code.exe ... I have also tried code and code.cmd . Why doesn't VS Code execute like other programs? And is there a way to enable the code command? EDIT: I now get these errors: me@mypc:/mnt/c/Users/me/Documents/project_folder$ code . /mnt/c/Program Files (x86)/Microsoft VS Code/bin/code: line 7: realpath: comma nd not found /mnt/c/Program Files (x86)/Microsoft VS Code/bin/code: line 14: ./Code.exe: No

chmod WSL (Bash) doesn't work

Deadly 提交于 2019-12-03 22:34:24
Running bash on windows 10, the simple syntax below works when I SSH to my webserver, but not when I exit out and am on my local machine. It doesn't give me an error, but I can see permissions are unchanged. I have to checked that I am set up as an administrator on my computer. Is this an error or is this just a consequence of the local operating system being windows? IF the later, it makes me question the value of using bash on windows if common operations such as this won't work. $chmod 644 filename Amade's answer is correct, but please note, the cmd only take effect in session scope. If you

Show matplotlib plots in Ubuntu (Windows subsystem for Linux)

十年热恋 提交于 2019-12-03 18:20:47
问题 So it seems on ubuntu for windows (windows subsystem for linux) people are suggesting we need to use Agg backend and just save images, not show plots. import matplotlib matplotlib.use('Agg') # no UI backend import matplotlib.pyplot as plt import numpy as np t = np.arange(0.0, 2.0, 0.01) s = 1 + np.sin(2*np.pi*t) plt.plot(t, s) plt.title('About as simple as it gets, folks') #plt.show() plt.savefig("matplotlib.png") #savefig, don't show How could we get it to where plt.show() would actually

Unable to connect to server: postgresql on ubuntu in windows subsystem for linux

旧城冷巷雨未停 提交于 2019-12-03 17:33:56
I'm using WSL with an ubuntu 18.04 distribution, in the bash I hit sudo -u postgres psql I get the following error: psql: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5433"? Then I tried other postgres operations like: sudo -u createdb mydb only to get the same error. Please advise. When running PostgreSQL on Ubuntu in Windows Subsystem for Linux, you may have to manually start the db server before you can connect. Use the command below to start your db server and then try