Silver Searcher – How to ignore a file
Put the list of files to exclude in .agignore. Note: as @DenilsonSáMaia mentioned, .agignore will be deprecated in favor of .ignore geoff.greer.fm/2016/09/26/ignore
Put the list of files to exclude in .agignore. Note: as @DenilsonSáMaia mentioned, .agignore will be deprecated in favor of .ignore geoff.greer.fm/2016/09/26/ignore
You can also select your default terminal by pressing F1 in Visual Studio Code and typing/selecting Terminal: Select Default Profile (or Terminal: Select Default Shell in older Visual Studio Code versions). Older:
Based on Andrew Lessard’s answer, here’s a function to run a command and return the output as a string – Public Function ShellRun(sCmd As String) As String ‘Run a shell command, returning the output as a string Dim oShell As Object Set oShell = CreateObject(“WScript.Shell”) ‘run command Dim oExec As Object Dim oOutput As Object … Read more
The runas command does not allow a password on its command line. This is by design (and also the reason you cannot pipe a password to it as input). Raymond Chen says it nicely: The RunAs program demands that you type the password manually. Why doesn’t it accept a password on the command line? This … Read more
echo %ERRORLEVEL% From TechNet, Command shell overview: “%ERRORLEVEL% … Returns the error code of the most recently used command. A non zero value usually indicates an error.” To test for specific error levels in batch files, you may find this knowledgebase article useful.
This is actually documented in the ReleaseNotes file (in the top level folder of your installed Git for Windows) Also, extra care has to be paid to pass Windows programs Windows paths, as they have no clue about MSys style POSIX paths — You can use something like $(cmd //c echo “$POSIXPATH”). If you use … Read more
In Windows you can open Explorer with the following command: C:\Users\Leniel>start %windir%\explorer.exe If you want it to open a specific folder, do this for example: C:\Users\Leniel>start %windir%\explorer.exe “C:\Users\Leniel\Desktop”
Here is an example I have found in my snippets. Hopefully it is a little bit more comprehensive. First you need to create a file system watcher and subsequently you subscribe to an event that the watcher is generating. This example listens for “Create” events, but could easily be modified to watch out for “Change”. … Read more
Delete all files with extension .tmp in current folder: On Windows: del *.tmp On Mac: rm -rf ./*.tmp Delete all files with extension .tmp in current folder Recursively (including sub-folders): On Windows: del /s *.tmp On Mac: find . -name ‘*.tmp’ -delete
I tested below code with SQL Server 2008 R2 Express and I believe we should have solution for all 6 steps you outlined. Let’s take on them one-by-one: 1 – Enable TCP/IP We can enable TCP/IP protocol with WMI: set wmiComputer = GetObject( _ “winmgmts:” _ & “\\.\root\Microsoft\SqlServer\ComputerManagement10”) set tcpProtocols = wmiComputer.ExecQuery( _ “select * … Read more