Mercurial > core / lisp/lib/skel/core/proto.lisp
changeset 690: |
90417ae14b21 |
parent: |
cc89b337384b
|
author: |
Richard Westhaver <ellis@rwest.io> |
date: |
Tue, 01 Oct 2024 23:34:01 -0400 |
permissions: |
-rw-r--r-- |
description: |
added io/fast, moved obj/music -> aud/music |
2 (in-package :skel/core/proto) 4 (deftype vc-designator () `(member :hg :git list)) 6 ;; ref: https://spdx.org/licenses/ 7 (deftype license-designator () `(or null string pathname (member :mpl2 :wtfpl :lgpg :llgpl :gpl :mit :mit0))) 9 (deftype script-designator () '(member :bin :sh :bash :zsh :nu :lisp :python)) 11 (deftype document-designator () '(member :org :txt :pdf :html :md)) 13 (deftype stack-slot-kind () '(member :shell :lisp :comment :var :rule :directive :nop)) 15 (deftype contact-designator () '(or string (cons string string))) 17 (defgeneric sk-run (self) 18 (:documentation "Run the object SELF.")) 19 (defgeneric sk-new (self &rest args &key &allow-other-keys) 20 (:documentation "Create a fresh instance of object SELF.")) 21 (defgeneric sk-save (self) 22 (:documentation "Save object SELF.")) 23 (defgeneric sk-tangle (self &rest params &key &allow-other-keys) 24 (:documentation "Tangle object self with params")) 25 (defgeneric sk-weave (self) 26 (:documentation "Weave object self with params")) 27 (defgeneric sk-call (self arg) 28 (:documentation "Call SELF with ARG.")) 29 (defgeneric sk-call* (self &rest args) 30 (:documentation "Call SELF with ARGS.")) 31 (defgeneric sk-print (self &key &allow-other-keys) 32 (:documentation "Print object SELF.")) 33 (defgeneric sk-load (self &key &allow-other-keys) 34 (:documentation "Load or reload object SELF.")) 35 (defgeneric sk-load-component (kind form &optional path) 36 (:documentation "Load a component of type KIND from provided FORM, producing an SK-COMPONENT 37 type. Usually calls SK-TRANSFORM or SK-CONVERT internally. 39 PATH is an optional directory pathname which will be merged with a filename 40 found in FORM. Defaults to *DEFAULT-PATHNAME-DEFAULTS*.")) 41 (defgeneric sk-compile (self &key &allow-other-keys) 42 (:documentation "Compile object SELF.")) 43 (defgeneric sk-build (self &key &allow-other-keys) 44 (:documentation "Build a skel-object.")) 45 (defgeneric sk-install (self &key &allow-other-keys) 46 (:documentation "Install a skel-object.")) 47 (defgeneric sk-test (self &key &allow-other-keys) 48 (:documentation "Test a skel-object.")) 49 (defgeneric sk-deploy (self &key &allow-other-keys) 50 (:documentation "Deploy a skel-object.")) 51 (defgeneric sk-fetch (self &key &allow-other-keys) 52 (:documentation "Fetch a skel-object.")) 53 (defgeneric sk-pack (self &key &allow-other-keys) 54 (:documentation "Pack a skel-object.")) 55 (defgeneric sk-unpack (self &key &allow-other-keys) 56 (:documentation "Unpack a skel-object.")) 57 (defgeneric sk-bundle (self &key &allow-other-keys) 58 (:documentation "Bundle a skel-object.")) 59 (defgeneric sk-unbundle (self &key &allow-other-keys) 60 (:documentation "Unbundle a skel-object.")) 61 (defgeneric sk-transform (self other &key &allow-other-keys) 62 (:documentation "Transform SELF to skel-object of type OTHER.")) 63 (defgeneric sk-convert (self) 64 (:documentation "Convert the object SELF.")) 65 (defgeneric sk-read (self stream) 66 (:documentation "Read and fill SELF with an object from STREAM.")) 67 (defgeneric sk-read-file (self path) 68 (:documentation "Read a PATH from the filesystem with SELF.")) 69 (defgeneric sk-write (self stream) 70 (:documentation "Write object SELF to STREAM.")) 71 (defgeneric sk-writeln (self stream) 72 (:documentation "Write a line from SELF to STREAM.")) 73 (defgeneric sk-write-string (self) 74 (:documentation "Return a string from SELF.")) 75 (defgeneric sk-write-file (self &key path &allow-other-keys) 76 (:documentation "Write from SELF to file PATH.")) 77 (defgeneric sk-install-user-config (self cfg) 78 (:documentation "Populate SELF with configuration object CFG.")) 79 (defgeneric sk-vc-push (self &key remote &allow-other-keys) 80 (:documentation "Push object SELF upstream using vc.")) 81 (defgeneric sk-vc-pull (self &key remote &allow-other-keys) 82 (:documentation "Pull object SELF from upstream using vc.")) 83 (defgeneric sk-find-rule (name self) 84 (:documentation "Find a rule with the given NAME in SELF.")) 85 (defgeneric sk-find-script (name self &key &allow-other-keys) 86 (:documentation "Find a script with the given NAME in SELF.")) 87 (defgeneric sk-find (item self &key &allow-other-keys)) 88 (defgeneric sk-find* (items self &key &allow-other-keys)) 89 (defgeneric sk-path (self) 90 (:documentation "Return the canonical path to this object in the skel universe.")) 91 (defgeneric sk-path-merge (self root) 92 (:documentation "Merge path of SELF on ROOT."))