Kategorien
Allgemein Git - Github

Basic Git Commands

BASIC COMMANDS

$ git init // Initialize a local Git Repo
$ git add // Add file(s) to index (to the staging area)
$ git status // Check status of working tree will display diffs between working tree and staging area
$ git add *.html // will add all html files to the staging area
$ gitt add . // adss everything to the staging area
$ git commit // Commit changes to index (Puts everything in to the local repo)
$ git touch .ignore // Creates a Git ignore file
$ git commit -m ‘message’ // Commits with message includedgit commit -m
$ git rm –cached // Unstage or delete from staging area
$ clear // Clears the screen

Working with Github
$ git push // Push to rem Repo (credentials or SSH keys required)
$ git pull // Pull latest from rem Repo
$ git clone // Clones a rem Repo to your machine
$ git branch mybranch // Creates a branch named mybranch

$ git config –global // configure git globally $ git config –global user.name ‘Username’

Kategorien
News Operating Systems Windows

Robocopy

Syntax: robocopy source destination modifier-switches
All information can be accessed using robocopy /?

Copy Options:
/E copies subdirectories even when empty
/PURGE delete destination files/dirs that no longer exist in source
/MIR Mirror a directory tree = equivalent to /E plus /PURGE produces identical duplicate folders
Files or folders deleted in original will be deleted in the destination
/MT[:n] Do mulithreaded copies with n threads (default is 8) n>1 n<128

Retry Options:
/R:5 number of Retries on failed copies (default is 1 million)
/W:15 wait time 15 sec for each retry

Logging switches:
/NS no file sizes reported
/NC no class reported
/NFL no file list
/NDL no directory list
/NP no progress
/LOG:\directory\filename.txt starts (replaces) log file
/LOG+:\directory\filename.txt appends to existing log file

  • Note: Don’t use mapped drive paths!
  • Note: Use Quotes for any path that includes a space like “\server\office docs”
  • Note: Do not call the text file robocopy.bat
  • Note: Remember to create directory c:\robologs
robocopy \\Source\Folder Z:\DestinationFolder /MIR /MT /R:5 /W:15 /NS /NC /NFL /NDL /NP /LOG+:\robologs\log.txt
  • create a .bat file and run as an administrator
  • The best way is to use a task scheduler : schedtasks
Kategorien
Operating Systems Windows

Location of desktop background

Windows 10: Where is the current desktop background image located?

Hit Win+r 
%AppData%\Microsoft\Windows\Themes\CachedFiles

You don’t need administrative rights for this and you don’t need to edit anything in the address.

Kategorien
News Operating Systems Windows

Map a Network Drive using Command Line

To map Network Drives using the command line, in an elevated command prompt, you have to run the following command:

net use x: \server\share /persistent:yes

Here x is the drive letter, and the /persistent: yes parameter makes it permanent.

Kategorien
News Operating Systems Windows

Run Commands Every Windows User Should Know

Command Description
\ c:\
appwiz.cpl Program and Features
calc Calculator
cmd Comand
compmgmt.msc Computer management
control Control Panel
devmgmt.msc Device Manager
eventvwr.msc Event Viewer
firewall.cpl Firewall
gpedit.msc Group Policy Editor
msconfig System Configuration
msinfo32 Info
mstc Remote Desktop Connection
ncpa.cpl Network Adaptors
netplwiz general User accounts
netplwiz User accounts
notepad Notepad
powercfg.cpl Power Options
powershell powershell
regedit Registry
resmon Resource Manager
services.msc Services
sysdm.cpl System Properties
taskmgr Taskmanager
wordpad Wordpad

Unless indicated otherwise, all the commands above work in all versions of Windows from Vista upwards.
Most of these utilities can be found in %systemroot%\System32\