1 ;;; cdl.el -- Common Data Language (CDL) utility functions for Gnu Emacs
3 ;; Copyright (C) 1993 Free Software Foundation, Inc.
5 ;; Author: ATAE@spva.physics.imperial.ac.uk (Ata Etemadi)
8 ;; This file is part of GNU Emacs.
10 ;; GNU Emacs is free software; you can redistribute it and/or modify
11 ;; it under the terms of the GNU General Public License as published by
12 ;; the Free Software Foundation; either version 2, or (at your option)
15 ;; GNU Emacs is distributed in the hope that it will be useful,
16 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ;; GNU General Public License for more details.
20 ;; You should have received a copy of the GNU General Public License
21 ;; along with GNU Emacs; see the file COPYING. If not, write to
22 ;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
26 (defun cdl-get-file (filename)
27 "Run file through ncdump and insert result into buffer after point."
28 (interactive "fCDF file: ")
29 (message "ncdump in progress...")
30 (let ((start (point)))
31 (call-process "ncdump" nil t nil
(expand-file-name filename
))
33 (message "ncdump in progress...done"))
35 (defun cdl-put-region (filename start end
)
36 "Run region through ncgen and write results into a file."
37 (interactive "FNew CDF file: \nr")
38 (message "ncgen in progress...")
39 (call-process-region start end
"ncgen"
40 nil nil nil
"-o" (expand-file-name filename
))
41 (message "ncgen in progress...done"))