From owner-freebsd-multimedia Thu Nov 21 13:51:29 2002 Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 347AF37B401 for ; Thu, 21 Nov 2002 13:51:27 -0800 (PST) Received: from hindenburg.eboai.org (hindenburg.eboai.org [206.183.134.245]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4899843EAC for ; Thu, 21 Nov 2002 13:51:24 -0800 (PST) (envelope-from chip@chocobo.cx) Received: by hindenburg.eboai.org (Postfix, from userid 1000) id 46ED25E3CC; Thu, 21 Nov 2002 16:51:23 -0500 (EST) Date: Thu, 21 Nov 2002 16:51:23 -0500 From: Chip Marshall To: John Barlow Cc: freebsd-multimedia@FreeBSD.ORG Subject: Re: running xmms from cron Message-ID: <20021121215123.GA53141@chocobo.cx> Reply-To: chip@chocobo.cx Mail-Followup-To: John Barlow , freebsd-multimedia@FreeBSD.ORG References: <3DDD8821.6090807@starkube.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="PEIAKu/WMn1b1Hv9" Content-Disposition: inline In-Reply-To: <3DDD8821.6090807@starkube.net> X-URL: http://www.chocobo.cx/chip/ X-OS: FreeBSD 4.6-RELEASE-p2 i386 up 6 days User-Agent: Mutt/1.5.1i Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org --PEIAKu/WMn1b1Hv9 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On November 21, 2002, John Barlow sent me the following: > I would like to make cron open xmms and stream my favorite radio shows.= =20 > Using crontab -e I created a schedule that follows this format: >=20 > # wake up with KEXP 0622AM Monday - Friday > 22 6 * * 1-5 oenomaus xmms=20 > /usr/home/oenomaus/streams/kexp.pls >=20 > # listen to the news @ 0730 > 30 7 * * 1-5 oenomaus xmms=20 > /usr/home/oenomaus/streams/kuow.pls Unless this is the system crontab (/etc/crontab) you don't need to specify a username. I don't know off the top of my head if it will break because of that though. =20 I think the problem here is that cron does not run these commands with the same environment that your shell does. In particular, without a DISPLAY variable, I don't think xmms will know how to connect to X. In an xterm, try running "echo $DISPLAY" and adding whatever's it's value is to your crontab on a line of it's own, something along the lines of: DISPLAY=3D:0.0 It's a little hacky, but it should work, I think. --=20 Chip Marshall http://www.chocobo.cx/chip/ GCM/CS d+(-) s+:++ a21>? C++ UB++++$ P+++$ L- E--- W++ N@ o K- w O M+ V-- PS+ PE Y+ PGP++ t+@ R@ tv@ b++@ DI++++ D+(-) G++ e>++ h>++ r++ y? --PEIAKu/WMn1b1Hv9 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iD8DBQE93VVa8vyTVl6qbdQRApbVAJ9TxdGcMwCphXDUmswKwSUmoPe95ACfXSss v0nH3bgCfGaGq831AKlHHDA= =YhxC -----END PGP SIGNATURE----- --PEIAKu/WMn1b1Hv9-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-multimedia" in the body of the message