Notes by woolf

Displaying keyword search results 1 - 12
Created by woolf on December 29, 2011 11:18:11    Last update: December 29, 2011 11:18:11
Use the expand command to extract files from a .cab file: expand [-r] source [destination] [-d source.cab ... Option Description [-r] Renames expanded files. [destination] Specifies where files are to be expanded. If source is multiple files and -r is not specified, destination must be a directory. destination can consist of a drive letter and colon, a directory name, a file name, or a combination of any of these. [-d source.cab] Displays a list of files in the source location. Does not expand or extract the files. [-f:files] Specifies the files in a cabinet (.cab) file that you intend to expand. You can use wildcards (* and ?). source.cab Specifies the files to expand. source can consist of a drive letter and colon, a directory...
Created by woolf on September 08, 2011 11:19:52    Last update: September 08, 2011 11:19:52
To check a command exists on PATH: Use the return code of which : which some_command &>/dev/null [ $? -eq 0 ] || ... For bash, use type -P : type -P some_command &>/dev/null && echo "ome_comm... or check_path() { if ! type -P $1 &> /dev/...
Created by woolf on August 07, 2011 18:52:12    Last update: August 07, 2011 18:52:12
Running this command: # /usr/sbin/iptables -t nat -A PREROUTING -p tcp -... produced this error: iptables v1.4.6: unknown option `--to-ports' Tr... To fix: # opkg install iptables-mod-nat-extra
Created by woolf on July 03, 2011 19:29:45    Last update: July 05, 2011 08:28:06
eHow gave this command for defragging NTFS in Linux: fsck -t ntfs --kerneldefrag /dev/XXX which was rebuked by stack exchange . I believe the latter is right: there's no such thing! Yes, there's a set of utilities called ntfsprogs (including ntfsresize, which is widely used), but defragmentation does not seem to be part of it.
Created by woolf on June 18, 2011 21:21:56    Last update: June 18, 2011 21:34:56
I haven't test these. They are collected for reference only. With mencoder, from HOWTO: Convert and write AVCHD (.mts) to DVD with Linux mencoder -oac copy -ovc lavc -of mpeg -mpegopts fo... With HandBrake (GUI): Transcoding AVHD (Cannon HF100 .mts) into a usable open format (MKV w/ FFMPEG) With ffmpeg & WinFF (GUI and command line): How to convert Canon .mts video files to other formats in Ubuntu With mencoder, from Transcoding AVCHD (.mts or .m2ts) files using mencoder on Linux (no deinterlacing): # 1 pass mencoder $file -o ./$file.avi -oac cop... With ffmpeg, from Stuttering playback of canon MTS files #!/bin/bash for i in "$i"*.MTS; do name="${i%.*... #!/bin/bash for i in "$i"*.MTS; do name="${i%.*... With mencoder, from [MEncoder-users] problems with AVCHD (.mts) + Deinterlace...
Created by woolf on May 15, 2011 14:35:58    Last update: May 15, 2011 14:36:47
Assign IP adrress and network mask: sudo ifconfig eth0 192.168.183.5 netmask 255.255.2... Add default gateway: sudo route add default gw 192.168.183.2 Add name server: " sudo vi /etc/resolv.conf " and add: nameserver 192.168.183.2
Created by woolf on February 10, 2011 13:29:31    Last update: February 10, 2011 13:31:37
This command script redirects all stdout and stderr to a file with current date and time. @echo off @rem Send STDOUT/STDERR to file with ...
Created by woolf on February 10, 2011 13:25:20    Last update: February 10, 2011 13:25:20
If Command Extensions are enabled (which is enabled by default), then there are several dynamic environment variables that can be expanded but which don't show up in the list of variables displayed by SET . These variable values are computed dynamically each time the value of the variable is expanded (but see example below). If the user explicitly defines a variable with one of these names, then that definition will override the dynamic one described below: %CD% - expands to the current directory string. %DATE% - expands to current date using same format as DATE command. %TIME% - expands to current time using same format as TIME command. %RANDOM% - expands to a random decimal number between 0 and 32767. %ERRORLEVEL% - expands to the...
Created by woolf on February 10, 2011 12:51:14    Last update: February 10, 2011 13:06:11
Windows command line shell does not come with a sleep command. One trick is to emulate sleep using the ping command: C:\>ping /? Usage: ping [-t] [-a] [-n count... To sleep for about 5 seconds: @rem make sure to ping a non-existing IP, otherwis... If you have the Windows Resource Kit installed, it does provide a sleep command: C:\>sleep Usage: sleep time-to-sleep-in-s...
Created by woolf on October 22, 2010 02:53:32    Last update: October 22, 2010 03:18:12
The easiest way to shutdown Windows XP with a shortcut is to create a shortcut icon on the desktop (or the Start menu, or the Quick Launch menu) and assign a shortcut key combination. Useful command line commands: Shutdown : shutdown -s -t 0 Restart : shutdown -r -t 0 Log off : shutdown -l -t 0 Hibernate : rundll32.exe PowrProf.dll, SetSuspendState Hibernate Command line options for shutdown : C:\> shutdown /? Usage: shutdown [-i | -l | -s ...
Created by woolf on December 28, 2009 00:11:20    Last update: January 15, 2010 04:01:46
From http://www.videohelp.com/tools/MJPEG_Tools : A sample command line to deinterlace dv footage, give a slight film look, pass it through a Spatial-Pre-Filter, Temporal-Noise-Filter, and a Spatial-Post-Filter, then encode to DVD complient mpeg2 video looks like this - lav2yuv capture.dv | yuvdeinterlace -f | yuvdenois... From http://www.linux.com/archive/feature/40069 , the actual video file can be used in place of edit list (eli) file: # de-noice the video and scale for DVD output l...
Created by woolf on January 24, 2009 04:01:26    Last update: January 24, 2009 04:01:26
Command Meaning ./configure configure the package for your system make compile the package make install install the programs and man pages make clean remove the program binaries and object files make distclean make clean, but also remove the files that 'configure' created