03-31-2016
Why use shell magic cookie instead of awk one as interpreter ?
Should one use #!/bin/ksh .. awk '.. or just !#/usr/bin/awk -f or even /usr/bin/env awk ?
What should be most portable, preferred and/or standards compliant?
Regards
Peasant.
This User Gave Thanks to Peasant For This Post:
8 More Discussions You Might Find Interesting
1. Programming
IKHz_SW_OSX.py
A DEMO mono _pure_ sinewave generator using standard text mode Python 2.6.7 to at least 2.7.3.
This code is EASILY modifyable to Python version 3.x.x...
This DEMO kids level 1KHz generator is mainly for a MacBook Pro, (13 inch in my case), OSX 10.7.5 and above. See below...... (0 Replies)
Discussion started by: wisecracker
0 Replies
2. Shell Programming and Scripting
A very simple crude sinewave generator.
The file required is generated inside the code, is linear interpolated and requires /dev/audio to work. Ensure you have this device, if not the download oss-compat from your OS's repository...
It lasts for about 8 seconds before exiting and saves a... (5 Replies)
Discussion started by: wisecracker
5 Replies
3. Shell Programming and Scripting
Thanks Guys
This really helped (5 Replies)
Discussion started by: robert89
5 Replies
4. Slackware
I'm trying to record audio using Audacity 2.0.5 installed from SlackBuilds. My system is 64-bit Slackware 14.1 and a sound card is Intel HD Audio. I didn't change my sound system to OSS. (Default sound system in Slackware 14.1 is ALSA, isn't it?) First, I set Internal Microphone slider in KMix... (2 Replies)
Discussion started by: qzxcvbnm
2 Replies
5. OS X (Apple)
This is a small program as a tester for a basic sweep generator for bandwidth testing of AudioScope.sh.
This DEMO is only capable of 4KHz down to about 85Hz and back due to the low bit rate, but it is proof of concept for a much wider variant using a much higher bit rate.
The file generated... (4 Replies)
Discussion started by: wisecracker
4 Replies
6. OS X (Apple)
Hi all...
I intend to do an Audio Function Generator using Awk, (already started thanks to Don), but the biggest thing I have struggled with was variable frequency.
I was going to generate differing sized waveforms on the fly but that would that would mean the frequencies are dependent on any... (2 Replies)
Discussion started by: wisecracker
2 Replies
7. OS X (Apple)
Hi all...
Well I have not been inactive but working out how to make OSX 10.14.x command line audio player have a variable sample rate.
This is a back door as afplay does not have a sample rate flag unlike aplay for ALSA, in Linux flavours.
This is a DEMO only but a derivative of it will... (2 Replies)
Discussion started by: wisecracker
2 Replies
8. Shell Programming and Scripting
Hello
I use a bash script to creating the hosts file /etc/hosts
But there is a bug inside my output and I want to fix this.
My Array looks like this:
205,IP 111.122.133.20
205,HOST2 unas
205,HOST1 unas15533
205,COMMENT # UNAS
775,IP ... (9 Replies)
Discussion started by: Marti95
9 Replies
LEARN ABOUT CENTOS
package::generator
Package::Generator(3) User Contributed Perl Documentation Package::Generator(3)
NAME
Package::Generator - generate new packages quickly and easily
VERSION
version 0.103
SYNOPSIS
use Package::Generator;
my $package = Package::Generator->new_package;
...
DESCRIPTION
This module lets you quickly and easily construct new packages. It gives them unused names and sets up their package data, if provided.
INTERFACE
new_package
my $package = Package::Generator->new_package(\%arg);
This returns the newly generated package. It can be called with no arguments, in which case it just returns the name of a pristene
package. The "base" argument can be provided to generate the package under an existing namespace. A "make_unique" argument can also be
provided; it must be a coderef which will be passed the base package name and returns a unique package name under the base name.
A "data" argument may be passed as a reference to an array of pairs. These pairs will be used to set up the data in the generated package.
For example, the following call will create a package with a $foo set to 1 and a @foo set to the first ten counting numbers.
my $package = Package::Generator->new_package({
data => [
foo => 1,
foo => [ 1 .. 10 ],
]
});
For convenience, "isa" and "version" arguments may be passed to "new_package". They will set up @ISA, $VERSION, or &VERSION, as
appropriate. If a single scalar value is passed as the "isa" argument, it will be used as the only value to assign to @ISA. (That is, it
will not cause $ISA to be assigned; that wouldn't be very helpful.)
assign_symbols
Package::Generator->assign_symbols($package, @key_value_pairs);
This routine is used by "new_package" to set up the data in a package.
package_exists
... if Package::Generator->package_exists($package);
This method returns true if something has already created a symbol table for the named package. This is equivalent to:
... if defined *{$package . '::'};
It's just a little less voodoo-y.
AUTHOR
Ricardo SIGNES, "<rjbs@cpan.org>"
BUGS
Please report any bugs or feature requests to "bug-package-generator@rt.cpan.org", or through the web interface at <http://rt.cpan.org>. I
will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
COPYRIGHT
Copyright 2006 Ricardo Signes, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.16.3 2009-07-09 Package::Generator(3)