gnu-emacs-sources
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

synth.sh (add-on for synth.el) Re: synth.el v. 0.2dev


From: D Goel
Subject: synth.sh (add-on for synth.el) Re: synth.el v. 0.2dev
Date: Mon, 01 Aug 2005 09:58:14 -0400
User-agent: Gnus/5.1007 (Gnus v5.10.7) Emacs/21.4 (gnu/linux)

"D Goel" <address@hidden> writes:

>  synth.el --- music sheet player, synthesizer, music via bash scripts
>
> (The 2 bash scripts:
>
>  * beep_to_speaker.sh
>  * command-line invocation of synth.el
>
>  ...  which I posted separately a few hours ago, are probably briefly
> held up for moderator-review. If they don't show up by tomorrow, I
> will add "add-on for synth.el" (which, it seems, makes them pass
> automatic mod-check) to the subject and resend them. )


The posts haven't shown up. As promised, here is synth.sh, which helps
with the command-line invocation of synth.el

====================================================
#!/usr/local/bin/emacscvs --script
;; Time-stamp: <2005-07-31 15:54:19 deego>

;;  Note that you don't need this.  synth.el can generate bash
;;  equivalents for you which you can directly use from bash in any
;;  case.  
;; But, if you still want to be able to call synth.el from bash, you can
;; use this script to do so. 



;; Author: D. Goel
;; Copyright (C) 2005 and onwards  D. Goel



 
;; This file is NOT part of GNU Emacs.
 
;; This is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
 
;; This is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;; GNU General Public License for more details.

;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING.  If not, write to the
;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
;; Boston, MA 02111-1307, USA.
 

;; This works with gnu emacs cvs.  See this page for more:
;; http://www.emacswiki.org/cgi-bin/wiki/CategoryBatchMode


;; Example usages:


;; synth.sh  
;; (for some help) 

;; synth.sh :p "v3 o3 c d e f g a b c4"

;; synth.sh -p "v3 o3 c d e f g a b c4"

;; synth.sh :p "v3 o3 c d e f g a b c4" :o 2 

;; synth.sh :v -1 :p "v3 o3 c d e f g a b c4" :o 1 

;; synth.sh ":v" "-1" :p "v3 o3 c d e f g a b c4" :o 1 













(require 'cl)
(load "~/.emacs.script")
;; general helpful shell-scripting functions and setup, not necessary.
(unless (ignore-errors (require 'shs))
  (error "Cannot load shs.el.  Follow INSTALLATION, AND create .emacs.script"))

(require 'synth)
(require 'shs)
(require 'shs-utils)

(defun synth-sh-sh (&rest args)
  (shs-start)
  (let ((args1 
         (shsu-args-keywordify-odds args)))
    ;; debug
    (mapcar
     (lambda (arg)
       (shsm (format "%S .. %S" arg (type-of arg))))
     args1)

    (apply 'synth-sh args1)
    (shs-bye)))










(apply 'synth-sh-sh command-line-args-left)








reply via email to

[Prev in Thread] Current Thread [Next in Thread]