Comments (6)
https://www.raymond.cc/blog/task-scheduler-bypass-uac-prompt/
Task scheduler (Option 4) always works for me
Some additional changes required:
- trigger: on login (so it runs automatically)
- action: instead of running
c:\wsl-autostart\start.vbs
directly, runwscript
with argsc:\wsl-autostart\start.vbs
(so it doesn't ask "open with basic script host?")
from wsl-autostart.
You can try this way to make wsl appliaction autostart
Win + R, type shell:startup
and enter, add start-wsl.vbs
in startup folder
Content of start-wsl.vbs
Set ws = WScript.CreateObject("WScript.Shell")
cmd = "C:\Windows\System32\bash.exe -c ""bash /etc/init.sh"""
ws.Run cmd, 0, false
Set ws = Nothing
WScript.quit
then make root as default user,
run in command line
debian config --default-user root
from wsl-autostart.
Currently, no way to avoid this.
but you can disable the UAC.
from wsl-autostart.
I'm getting this as well, kind of annoying but I'll deal with it since it's such a useful script.
from wsl-autostart.
没有必要获取系统权限啊,可以以用户身份启动 wsl 和服务
from wsl-autostart.
Or Raymond's first option, Winaero Tweaker: Create an elevated shortcut by https://winaero.com/blog/create-elevated-shortcut-to-skip-uac-prompt-in-windows-10/ (or more conveniently by the Winaero Tweaker as pointed out at the end of these instruction) and put it into the startup folder C:\Users\<user name>\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup
from wsl-autostart.
Related Issues (7)
- README.md may include instructions to use windows admin tools instead of modifying registry HOT 1
- Switch from "wsl sudo" to "wsl -u root" HOT 3
- does this commands.txt support systemd?
- This only works if a user login windows HOT 2
- Fix for when installed in path with spaces HOT 2
- Windows scheduler ubuntu autostart HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wsl-autostart.