mirror of
https://github.com/roswell/roswell.git
synced 2026-09-10 07:16:17 -04:00
63 lines
2.7 KiB
HTML
63 lines
2.7 KiB
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="generator" content="pandoc">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">
|
|
<title>ros-init(1)</title>
|
|
<style type="text/css">code{white-space: pre;}</style>
|
|
<link rel="stylesheet" href="../ros.css">
|
|
<!--[if lt IE 9]>
|
|
<script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js"></script>
|
|
<![endif]-->
|
|
</head>
|
|
<body>
|
|
<header>
|
|
<h1 class="title">ros-init(1)</h1>
|
|
<ul>
|
|
<li class="author">Roswell Project Team</li>
|
|
</ul>
|
|
</header>
|
|
<p>ros-init - Create a roswell script (optionally based on a template)</p>
|
|
<h1 id="synopsis">Synopsis</h1>
|
|
<p><strong>ros init [TEMPLATE] NAME [ARGS...]]</strong></p>
|
|
<dl>
|
|
<dt>TEMPLATE</dt>
|
|
<dd><p>Specifies the name of a template, defaulted to <em>default</em> template. However, if <em>TEMPLATE</em> is not specified and <em>FILENAME</em> matches one of the templates being stored, then it automatically uses the template. To suppress this behavior, you should explicitly specify <em>TEMPLATE</em> as <em>default</em>.</p>
|
|
<p>Thus you are warned when you use this command from a shell script. In order to achieve a consistent and desired behavior, it is adviced that they should always explicitly specify the template name.</p>
|
|
</dd>
|
|
<dt>NAME</dt>
|
|
<dd><p>Specify the output filename, or "-" to indicate <em>stdout</em>. When <em>TEMPLATE</em> is <em>default</em>, it automatically appends a file type ".ros".</p>
|
|
</dd>
|
|
</dl>
|
|
<!-- # subcommands -->
|
|
<h1 id="description">Description</h1>
|
|
<p>Initialises a roswell file based on a template. User-specified templates can be added by <em><a href="ros-template.html">ros-template</a></em>(1).</p>
|
|
<p>The default template is something like:</p>
|
|
<pre><code>#!/bin/sh
|
|
#|-*- mode:lisp -*-|#
|
|
#| <Put a one-line description here>
|
|
exec ros -Q -- $0 "$@"
|
|
|#
|
|
(progn ;;init forms
|
|
(ros:ensure-asdf)
|
|
;;#+quicklisp (ql:quickload '() :silent t)
|
|
)
|
|
|
|
(defpackage :ros.script.test.3703600390
|
|
(:use :cl))
|
|
(in-package :ros.script.test.3703600390)
|
|
|
|
(defun main (&rest argv)
|
|
(declare (ignorable argv)))
|
|
;;; vim: set ft=lisp lisp:</code></pre>
|
|
<p>This is basically a shell script which immediately invokes Roswell by exec (see <em>sh(1)</em>). Roswell loads the same script as an input, skips multi-line comments, reads the rest of the file as a Common Lisp program, and finally invokes a function main with command-line arguments.</p>
|
|
<!-- # options -->
|
|
<!-- -->
|
|
<!-- # Environmental Variables -->
|
|
<h1 id="see-also">SEE ALSO</h1>
|
|
<p><em>sbcl</em>(1) <em><a href="ros.html">ros</a></em>(1) <em><a href="ros-template.html">ros-template</a></em>(1)</p>
|
|
<p>_</p>
|
|
</body>
|
|
</html>
|