NetPenguin: Quick toggle window style

If you use NetPenguin for your FTP needs, you’ll notice two small triangular widgets in the lower left and right of the main transfer window.

510.NetPenguin.png

Click the left one to show or hide your local filesystem. Click the right one to show or hide the transfer status panel.

 

slrn: Decode USENET binaries

At this time, there are no graphical newsreaders for BeOS that can easily display or launch uuencoded USENET binaries. However, the command-line SLRN newsreader makes this pretty easy. If you don’t have SLRN running already, get it installed and familiarize yourself with basic navigation.
Now, make sure you have a directory /boot/home/News.
If you want to decode a single-article binary, just select it in SLRN and tap : (the colon key). SLRN will suggest a filename for the raw file data — something like:

/boot/home/News/alt.binaries.pictures.fractals

Accept this filename by pressing „y“ and SLRN will save the raw data to disk. When done, SLRN will ask whether you want it decoded. Press „y“ and the uuencoded file will be passed to uudecode, which comes bundled with BeOS. When finished, you should have a new .jpg or .mp3 or whatever file in your ~/News folder, which you can double-click to launch. You’ll be asked whether you want to delete the input file. You’ll probably want to say yes.
If you’re dealing with a binary which spans multiple articles, you’ll need to tag those articles first so SLRN can treat them as a batch. Just press # next to each article header and the pieces will be numbered 1-7 or whatever. With the articles tagged, press : and proceed as above.
Before going to grab another binary, you’ll need to untag the currently tagged articles — do this with Esc-#.

 

Fastest way to database MP3s

Update: All of the principles in this tip still apply, but you can get most or all of this done much more easily with FlipSide’s MP3 Army Knife.
Since you’ll probably soon be using a BeIA-based home stereo component to play all of your MP3s through a central home server, you want to make sure you’ve got all your files ID3 tagged and attributed so you can run quick playlist queries through a Qubit Web pad from any room in the house. The time to get your database in order is now (even if you won’t be getting a BeIA home stereo device, this procedure is worth reading). Query-based playlists are a great BeOS advantage not easily replicated on other OSes.
id3attrs
If you’re encoding CDs to MP3, use a tool like RipEnc, which will make sure your files have appropriate ID3 tags and indexed attributes from the get-go. If you’re dealing with an existing collection copied over from another OS or have been downloading legal MP3 files, here’s the fastest way I’ve found to get everything in order. This may sound like a lot of work, but it’s actually very fast once you get the hang of the system.

Setup

  1. Make sure you’ve got the following tools installed: id3attr, id3ren, mp3tag, MP3 Tags and Attributes, Summon.
  2. If you want to be able to create query-based playlists later on, make sure you have appropriate indexes installed. For maximum query-ability, you’ll want to open a Terminal and run the following:
    mkindex Audio:Album
    mkindex Audio:Artist
    mkindex Audio:Comment
    mkindex Audio:Genre
    mkindex Audio:Title
    mkindex -t int Audio:Year
    

    Remember that indexes are per-volume, so if you have a large drive or drives you use for MP3 storage, do this procedure on each one, not just on your boot drive. See Manipulating filesystem indexes for more information on working with indexes.

  3. Add the following line to your /boot/home/.profile:
    alias idren='id3ren -template="%a - %s.mp3" -space=" "'

    This takes advantage of id3ren’s template naming feature, which will allow you to rename your files en masse, with consistent filenames.

Usage

  1. Sort your downloaded or copied MP3s into directories by artist and/or album (you’ve probably already done this).
  2. In an artist directory, tap Alt+A to select all, then Alt+Opt+M to bring up the MP3Tag Tracker add-on (Opt is your left Win key). This will let you batch tag all of the common fields, so you can set the artist, genre, and possibly other tags all at once. Pay special attention to the template feature in MP3Tag: If your files have consistent and reliable filenames, you can save yourself a lot of work by having MP3Tag automatically parse filenames into ID3 tags. Hit Save to commit the changes. If necessary, go back to the top of the directory and hit Alt+Opt+M for each file to enter the unique tags (song name, etc.), hitting Enter after each one.
  3. Launch a Terminal in that directory with Summon, by tapping Alt+Opt+S.
  4. Type id3attr *.mp3. This will copy all of the ID3 tags to corresponding attributes. BeOS will automatically add your attributes to the indexes, if you’ve installed them, so you can start running queries on those files‘ newly created attributes. If you prefer to do this part from the Tracker, use the „MP3 Tags and Attributes“ add-on, which will offer either to copy all ID3 tags into corresponding attributes, or to copy attributes into corresponding ID3 tags.
  5. Type idren *.mp3. This will rename all MP3s in the directory with the format:
    Artist Name - Song Name.mp3

    To use a different format, alter the template in the setup procedure above.

Sounds like a lot of work, but after you’ve got the setup done, the usage part is nearly painless, and the payoff in the long run will be worth it — especially if you have a large collection. You’ll be able to sort and sift through your MP3 in ways that aren’t possible on other platforms, and be able to create query-based playlists from any web interface.
See also:
Creating playlists from system queries
Manipulating filesystem indexes

 

BeBochs: Easy Windows installation

BeBochs lets you run Windows and Windows apps in a BeOS window. But if you’ve tried to set up BeBochs, you know it can be pretty difficult to install Windows 95 for use with BeOS. This technique can make things much easier, if you’ve got a spare slot on your IDE chain.
Get yourself a small hard drive and install it in your computer all by itself. Copy the Windows installation from CD to the hard drive, along with all the cab files, like this:

MKDIR C:WIN95
COPY X:WIN95*.* C:WIN95*.*

(where X is the letter of your CD-ROM drive).
Now go into C:WIN95 and type SETUP to install Windows. When finished, take your new Windows drive and put it on your secondary master IDE chain. Boot back into BeOS and start BeBochs. When the configuration window prompts you for a path, enter

/dev/disk/ide/ata/1/master/0/raw

If that doesn’t work, launch a Terminal and type df. Note the location of your Windows drive, but make sure the path says „raw“ at the end instead of 0_0 or something.
You should be all set.
If you need additional help, see the excellent instructions at Using BeBochs.

 

An alternative to bootman

Be’s bootman is easier to configure than nearly any boot manager on the market (it certainly blows LILO away in this department). However, bootman’s boot loader screen isn’t the prettiest, and it lacks some of the advanced features of other boot managers. There are a lot of boot managers out there — some are free, some are not, some are easy to set up, and some of them are hard. But none of them look as cool as XOSL!
XOSL, which stands for „Extended Opertating System Loader“ written by Geurt Vos, is a GNU app that can manage all of the operating systems installed on your machine, including BeOS, Linux, Solaris, W2K, W98SE, and more. And it looks great (see screenshots). While XOSL is distributed as a Windows installer, an option is also available for machines without a DOS/Win partition. See the Downloads section of the site.
Unfortunately, XOSL currently does not display BeOS on its OS menu. To set up XOSL for use with BeOS:

  1. Download XOSL from http://www.xosl.org
  2. Run the install.exe from DOS (you’ll have better luck with mouse detection than if you run it from Windows). XOSL can be installed on any partition of any hard disk.
  3. When the text screen appears, select Install XOSL 1.1.0
  4. Select the partition you want it on, for it to work right you need to place it on the disk you boot from
  5. Select your video mode and mouse, I used 800×600 for video and PS/2 for mouse
  6. Select Start Installation
  7. Select Reboot system (which just kicks you back to windows)
  8. Reboot your system

If you installed it on the right drive, the XOSL screen should appear. Now:

  1. Set your preferences, wallpaper, colors, mouse speed and so-on. You can even set a password. Select Save, then close (very important)
  2. Next select Setup, and select and name the partitions you want to boot.
  3. Select Save then close (again very important)
  4. Have Fun!
 

Show /boot/var in the Tracker

The directory /boot/var, which contains system log and temp files among other things, is hidden from the Tracker to discourage normal usage (although it is visible from File panels, so you can quickly open up log files in text editors when necessary).
If you do want to see the contents of /boot/var in the Tracker, just open a Terminal and type:

/system/Tracker /var &

(/var is a symlink to /boot/var).

 

Scheduled network restarts

The BeOS network stack is in the process of being completely re-written from scratch, and replaced with a high-powered stack based on BSD networking (see the BONE story at BeNews for more information). BONE is scheduled to be released as an upgrade some time after R5 is released.
Until that time, there are two instances in which it can be handy to be able to restart networking automatically according to a schedule or script. Specifically:

  1. If you’re running a BeOS web server, you’ll find that some tcp threads aren’t closed properly. Over time (around 14,000 hits), these unclosed threads can clog the network stack, which kills networking. To check on the status of these threads, type ps | grep tcp into a Terminal. Networking can be restarted without rebooting by clicking Restart Networking in Network prefs, but you’ll probably want to automate this so it happens at regular intervals without manual intervention. 
  2. If you connect via DHCP, your lease on given IP or DNS addresses may expire every day or two, depending on how your provider sets things up. You may want to have networking restarted every 24 hours or whatever to automatically grab new addresses. <./OL>First of all, you need a command capable of restarting networking, so you have something to invoke from your schedule or script. Grab this updated version of John Wiggins net_restart and see the included readme. You’ll need to compile the source for your platform; the instructions are very easy. Move the compiled net_restart binary to ~/config/bin.
    While your first instinct might be to invoke net_restart from cron, you’ll quickly discover that this isn’t so easy — cron doesn’t have access to all the environment variables networking needs to be restarted correctly. I wrestled with this for quite a while before giving up. Fortunately, there’s another way. Grab a copy of Brian Tietz‘ Scheduler from BeDepot. Invoke net_restart from Scheduler, and everything will work perfectly. Scheduler is also a native BeOS app rather than a port, and is 10x easier to use.
    That leaves one missing piece — when you restart networking, you’ll kill your web server. I use Robin Hood, and wrote a brief script to get around this problem. The script simply kills the Robin Hood daemon, runs net_restart, and restarts the daemon. Save this script as ~/config/bin/network_getup and invoke it from Scheduler, rather than net_restart itself. You may have to tweak some paths to match paths on your system.

    /bin/kill -9 rhdaemon
    /boot/home/config/bin/net_restart
    /boot/apps/net/RobinHood/server/rhdaemon &
 

Use SoftwareValet for batch transfers

You probably already know that SoftwareValet will let you stop and start downloads at will, and will let you queue up multiple downloads for batch transfers. Unfortunately, this usually only works when a software vendor provides a special link to a SoftwareValet download (e.g. at BeDepot).
With a quick hack, you can force SoftwareValet’s resumable download manager to give you resume capabilities for any file on the Internet, which is especially handy for very large downloads such as games. You can also queue up multiple files for batch transfer. Here’s how.
Create a plain text file containing the URLs to the files you want to download, one to a line. Precede each line with „url: “ so your file looks like this:

url: http://www.somesite.com/software/thisfile.zip
url: http://anothersite.com/music/junk.mp3
url: http://thirdsite.com/util.pkg

Save the file to the Desktop or wherever, then access its FileType panel (right-click | Add-Ons | FileType) and navigate to Application | SoftwareValet Download (or paste in application/x-scode-VDwn). Save and close the FileType panel.
Double-click the file, and SoftwareValet’s download manager will come up and start grabbing files, with full Defer/Activate controls.
The biggest drawback to this method is that all downloaded files will be given the SoftwareValet MIME type, so anything besides .pkg files will have to be given correct types manually.
See also Download Files While You Sleep.

 

Get detailed device info

Looking for a complete list of all the devices, IRQs, and memory addresses in use by your machine? Type

listdev

into a Terminal window and you’ll learn more than you probably wanted to know. This list is essentially the same info you can get from the Devices panel, but can be scanned and searched. To save the info to a text file, use

listdev > ~/device_info.txt

Another way to get info on your PCI bus from the terminal is to type poke. At the poke prompt, type help to see a list of options. Type pci to get a listing of all your PCI settings. It probably wouldn’t be a good idea to use any of the poke options that write to memory unless you really know what you’re doing!
Type quit to exit poke and return to your bash prompt.

 

People: Assign Person files to multiple groups

The Groups feature associated with People files is very powerful, and woefully underused (except by most BeOS email clients). If you’ve got several groups established and some of your colleagues belong in multiple groups, just select a group from the picklist multiple times. Alternatively, associate a person with multiple groups by separating the group names with commas.

 
 

Kategorien

 
 
Blogroll
Resources