LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Blogs
User Name
Password

Notices

Old

PlayShell 0.2-WP12A

Posted 12-31-2012 at 08:27 PM by konsolebox

PlayShell 0.2-WP12A was released yesterday.

It's the last version for 2012. Lots of important fixes and improvements were made there. It's pretty stable and consistent already compared to other earlier versions. An overhaul was made.

Hompepage: http://playshell.sourceforge.net/
SF.net summary page: http://sourceforge.net/projects/playshell
Release files: http://sourceforge.net/projects/play...hell/0.2-WP12A
Online repository: http://sourceforge.net/p/playshell/code/
Senior Member
Posted in Projects
Views 512 Comments 0 konsolebox is offline
Old

File conversion script

Posted 12-29-2012 at 10:04 AM by Snark1994
Updated 12-29-2012 at 10:10 AM by Snark1994

A handy script I put together to automatically convert between file formats based on file extension, in an easily extensible manner:

Code:
#!/usr/bin/env bash

#Conversion rules:
# commands["extension_from extension_to"]="convert_command"
# INFILE and OUTFILE in the conversion command are replaced
# with the appropriate filenames

declare -A commands
commands["wav mp3"]="ffmpeg -i INFILE OUTFILE"
...
Senior Member
Posted in Uncategorized
Views 434 Comments 0 Snark1994 is offline
Old

Bash quickie: loop N times, without doing math

Posted 10-22-2012 at 09:07 PM by the dsc (linux-related notes)
Updated 03-10-2013 at 12:25 AM by the dsc (improving, varible version)
Tags bash, loop

I thought that the only way to do such type of loop in Bash would require something like "n=$(($n+1))" within the loop, with the loop being conditioned to "n" adding up to whatever you want, such as "until ((n==30)) ; do". But you can actually do "for i in {1..20} ; do <whatever> ; done". That's somewhat similar to Basic's "for i=1 to 20 ; whatever ; next i".

But it won't work with variables for the starting and ending numbers....
Member
Posted in Uncategorized
Views 674 Comments 0 the dsc is offline
Old

Example script to run and manage a service (tcpdump) with managed logging.

Posted 10-11-2012 at 07:59 PM by konsolebox
Updated 10-12-2012 at 02:20 AM by konsolebox

I made this script as a reply to a question on a thread before. The accidentally simplified complexity of it amazes me so I thought that it would be nice to post this on a blog as well. Original thread: https://www.linuxquestions.org/quest...cpdump-800385/

The script runs and manages a service (tcpdump). It could also automatically delete files older than C days, and reduce the size of a logfile if it's already larger than N bytes....
Senior Member
Posted in Howtos
Views 942 Comments 0 konsolebox is offline
Old

libfind - Searches library files with keywords and paths from default values and /etc/ld.so.conf.

Posted 09-17-2012 at 01:03 AM by konsolebox
Updated 09-17-2012 at 06:23 AM by konsolebox
Tags bash, script

I made this utility along with binfind. It also has had lots of improvements since then.

This script can be used to search files contained in library files (*.so, *.la, *.a, etc.) based from keywords provided. Along with a custom list of default paths, it will search for libraries inside directories that are specified in /etc/ld.so.conf. It would also examine files that are specified by the "include" directive in it.

After preparations it would search for...
Senior Member
Posted in Howtos
Views 621 Comments 0 konsolebox is offline

  



All times are GMT -5. The time now is 01:25 AM.

Main Menu

My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration