Skip to content

Instantly share code, notes, and snippets.

@dobriak
Created November 10, 2012 23:02
Show Gist options
  • Save dobriak/4052882 to your computer and use it in GitHub Desktop.
Save dobriak/4052882 to your computer and use it in GitHub Desktop.
Automatically shut down Windows after a user specified interval.
@echo off
REM ---
REM AutoShutdown.bat
REM Shuts down Windows after a user specified interval
REM by Julian Neytchev https://github.com/dobriak
REM ---
REM How many minutes before shutdown? (Default:60)
SET MINUTES=60
SET /P MINUTES=Snooze minutes (60): %=%
REM Convert to seconds
SET /A SECONDS = 60*%MINUTES%
shutdown /s /t %SECONDS%
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment