Tag Info

New answers tagged

0

The scripts are run with "run-parts" - see man page: run-parts runs a number of scripts or programs found in a single directory directory. Filenames should consist entirely of upper and lower case letters, digits, underscores, and hyphens. Subdirectories of directory and files with other names will be silently ignored.


0

enable: netsh advfirewall set domainprofile firewallpolicy blockinboundalways,allowoutbound disable: netsh advfirewall set domainprofile firewallpolicy blockinbound,allowoutbound


2

The -exec argument to find simply executes that command on each item returned. So, for example, if you have a directory set like: >$ find . . ./a.txt ./b.txt ./dir1 ./dir1/c.txt ./dir2 ./dir2/d.txt The -exec portion will be run once for each line, substituting the text for {}. So, in your case, it would recursively copy each entry to the specified ...


0

I could find only a partial solution for the problem. The following script does the job of the KDE3 one-liner, but unfortunately it still requires a user interaction since plasma doesn't support script executions without a graphical user interface. That's very disappointing. If you know a way to execute plasma scripts directly please answer this question. ...


0

Look into Guard, in particular with this plugin: https://github.com/hawx/guard-shell You can set it up to watch any number of patterns in your project's directory, and execute commands when changes occur. Good chance even that there's a plugin available for that what you're trying to do in the first place.


-1

Windows 7 is fully capable of running a shutdown script through Local Group Policy.


0

This is not possible at shutdown. The only method of shutdown scripts is through group policy. The only option is to run it at the next reboot. The registry key for that is this: HKLM\Software\Microsoft\Windows\Current Version\RunOnce You can replace HKLM with HKCU (current user instead of local machine) but this will only run if the current user is ...


-1

Try this: #!/bin/bash function fs { ls -l LOGFILE | awk '{print $5}' } function lc { wc -l LOGFILE | awk '{print $1}' } function sv { fileSize=$(fs) fileLength=$(lc) } function ov { nFileSize=$(fs) nFileLeng=$(fs) } sv while true; do ov if [[ $nFileSize != $fileSize ]]; then newLines=$(tail -n $(($nFileLeng-$fileLength))) if [[ ...


1

1) In order not to have problems with the first line, make sure to kill all your script instances when (re)testing. e.g. killall <scriptname>. 2) Add the --batch parameter to your gpg command. Everything else should fine. Hope this helps.


0

From man screen: -dmS name Start as daemon: Screen session in detached mode. -r Reattach to a detached screen process. So you can start every command in its own screen daemon with a name, for example: screen -dmS port27015 ./srcds_run -console -game cstrike -tickrate 100 -pingboost 2 +map bhop_eazy -maxplayers 32 -port 27015 Now you can resume ...


1

AppleScript You can write a short AppleScript tell application "Finder" set the clipboard to "mylongemail@example.com" end tell Open the AppleScript Editor, paste the example and save it as an application. You can then put it in your dock to access it quickly. Terminal You can use pbcopy to copy text to the clipboard echo 'mylongemail@example.com' ...


0

I found this that helps a little. http://www.sevenforums.com/tutorials/285-sounds-change.html It doesn't tell you where everything is but if you're looking for a specific sound it works. The way I did it was to go to Control Panel > Sounds and find the sound i want to change for example i'll choose the Asterisk Sound under the WIndows section. So the ...


0

The easiest way to find this sort of stuff is to export the registry (HKEY_CURRENT_USER, usually), change the setting, export the registry again (to a different file) and run it through something like WinDiff or WinMerge to see what the differences are. Once you know what is changed, you can use something like VBScript to automate this: Option Explicit Dim ...


0

I suppose the options -b --backup-dir do not act as you hope. You can try to use a different option --link-dest instead. Your command line should be similar to the following rsync -aAXhH --link-dest=/scripts/full/ /scripts/source/ /scripts/diff/ What's the meaning? You are telling to rsync to compare the files in /scripts/source/ (the new ones) with ...


0

There's a cmdlet for that: Get-NetAdapter -Physical will give you information on your local interfaces. If you add the -CimSession parameter (Get-NetAdapter -Physical -CimSession), you can connect to a server by its ComputerName. You end up with: Get-NetAdapter -Physical -CimSession "ComputerName, ComputerName", where you can also fill ComputerName with a ...


3

I use the text expansion feature built into Mac OS X to automatically put in email address using a short abbreviations. This will work in standard text fields in Cocoa apps, like TextEdit, Mail etc; alternatively (paid) software like TextExpander (by Smile Software) works in apps like Sublime Text. Information here: ...


1

Something like this should do it: # An array of server names $servers = 'comp1','comp2','comp3','comp4'; Get-WmiObject -computer $servers -class win32_networkadapter | Where-Object AdapterType -eq 'Ethernet 802.3' | Format-Table -auto __SERVER,Caption,ServiceName,AdapterType, MacAddress with the result being something like (MAC addresses ...


0

As it turns out, the answer to this is that Illustrator is the wrong program, and that InDesign and its datamerge feature will produce the effect I'm looking for. Serves me right for over-specifying the parameters.


0

Till the code of the page will be of this type you can do it with a little script as the one below: MyUrl=$1 File_Url=$(wget -q -O - "$MyUrl") # here you put the file html in a variable Line=$(echo "$File_Url" |grep -e 'meta name="og:image"') # select only 1 line # echo $Line Img=$(echo $Line |sed -e 's/<meta name="og:image" content="//g' -e ...


0

Here's a quick solution in Applescript that could be triggered by a simple shortcut: tell application "iTunes" if player state is stopped then playpause else playpause tell application "VLC" to activate tell application "System Events" to keystroke space end if end tell


1

No, at least not to obtain the end you seek. Freegate operates as a proxy. it is not changing your IP address, its just forwarding on your traffic so it looks like the traffic is coming from them, not from you. This is not something you can do, because you'd be masquerading as yourself, which obiviously won't fool anyone. no scripting on your end will ...


2

Yes, it is possible. First play your video to see if it is OK: ffplay -i YourMovie.mp4 -vf "cropdetect=24:16:0" The cropdetect filter values are: cropdetect=limit:round:reset limit = black threshold (default 24) round = output resolution must be divisible to this reset = after how many frames the detection process will start over If it looks OK, crop ...


0

This is possible since you can use macruby's bridge support to control itunes and VLC's interfaces over TCP. You can find the required material from these links http://merbist.com/2010/01/17/controlling-itunes-with-macruby/ https://github.com/arcresu/vlcrc Don't expect the answer to be as short as you believed. You will have to do the coding yourself as I ...


2

Batch can't do this. But PowerShell can Here is a very simple example to open two Internet Explorer windows and move/resize them $ie1 = new-object -comobject InternetExplorer.Application $ie1.navigate("http://google.com") $ie1.visible = $true $ie1.top = 10 $ie1.width = 790 $ie1.height = 790 $ie1.Left = 10 $ie2 = new-object -comobject ...



Top 50 recent answers are included