rename relish to flesh
This commit is contained in:
parent
415b1181fa
commit
9b447eb5b7
58 changed files with 252 additions and 245 deletions
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/relish
|
||||
#!/bin/flesh
|
||||
|
||||
;; relish: versatile lisp shell
|
||||
;; Copyright (C) 2021 Aidan Hahn
|
||||
;; Flesh: Flexible Shell
|
||||
;; Copyright (C) 2021 Ava Affine
|
||||
;;
|
||||
;; This program is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -19,7 +19,7 @@
|
|||
;; AVA'S LAPTOP PROMPT
|
||||
;; This file contains a shell prompt configuration that outputs current dir
|
||||
;; username, and percentages for all batteries on the system.
|
||||
;; -> requires CFG_RELISH_POSIX=true and userlib.
|
||||
;; -> requires CFG_FLESH_POSIX=true and userlib.
|
||||
|
||||
(def _batteries 'paths to batteries powering system'
|
||||
(lambda ()
|
||||
|
|
@ -53,7 +53,7 @@
|
|||
(set (q bat-iter) (pop rem))))
|
||||
display)))
|
||||
|
||||
(def CFG_RELISH_R_PROMPT 'display battery info'
|
||||
(def CFG_FLESH_R_PROMPT 'display battery info'
|
||||
()
|
||||
(display-batteries))
|
||||
|
||||
|
|
@ -92,7 +92,7 @@
|
|||
")")
|
||||
''))
|
||||
|
||||
(def CFG_RELISH_L_PROMPT 'display user and dir (git info in future)'
|
||||
(def CFG_FLESH_L_PROMPT 'display user and dir (git info in future)'
|
||||
()
|
||||
(concat
|
||||
"[" USER "]" "\t"
|
||||
12
snippets/basic_minimal_configuration.f
Normal file
12
snippets/basic_minimal_configuration.f
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
;; comment out to load USERLIB
|
||||
;; (call (concat HOME "/.flesh/userlib.f"))
|
||||
|
||||
;; if you have userlib
|
||||
;; (set CFG_FLESH_POSIX "1")
|
||||
;; else
|
||||
(def CFG_FLESH_POSIX
|
||||
(get-doc (q CFG_FLESH_POSIX))
|
||||
"1")
|
||||
|
||||
(echo "Welcome back to Flesh.")
|
||||
(echo "Enjoy your computing.")
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
;; comment out to load USERLIB
|
||||
;; (call (concat HOME "/.relish/userlib.rls"))
|
||||
|
||||
;; if you have userlib
|
||||
;; (set CFG_RELISH_POSIX "1")
|
||||
;; else
|
||||
(def CFG_RELISH_POSIX
|
||||
(get-doc (q CFG_RELISH_POSIX))
|
||||
"1")
|
||||
|
||||
(echo "Welcome back to relish.")
|
||||
(echo "Enjoy your computing.")
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/relish
|
||||
#!/bin/flesh
|
||||
|
||||
;; relish: versatile lisp shell
|
||||
;; Copyright (C) 2021 Aidan Hahn
|
||||
;; Flesh: Flexible Shell
|
||||
;; Copyright (C) 2021 Ava Affine
|
||||
;;
|
||||
;; This program is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -54,4 +54,4 @@ Or, a more advanced use:
|
|||
(cons set (cons q (q arg-iter)) (cons pop (cons cdr (q arg-iter)))))
|
||||
(cons echo '+ ' (cons cdr (cons pop (q func-call))))
|
||||
(cons eval (q func-call))))))
|
||||
(eval lam)))
|
||||
(eval lam)))
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/relish
|
||||
#!/bin/flesh
|
||||
|
||||
;; relish: versatile lisp shell
|
||||
;; Copyright (C) 2021 Aidan Hahn
|
||||
;; Flesh: Flexible Shell
|
||||
;; Copyright (C) 2021 Ava Affine
|
||||
;;
|
||||
;; This program is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: highly versatile lisp interpreter
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: highly versatile lisp interpreter
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/* relish: versatile lisp shell
|
||||
* Copyright (C) 2021 Aidan Hahn
|
||||
* Copyright (C) 2021 Ava Affine
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
|
|||
15
snippets/mood-prompt.f
Normal file
15
snippets/mood-prompt.f
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/flesh
|
||||
|
||||
(def __mood 'current mood' ':3')
|
||||
|
||||
(def CFG_FLESH_L_PROMPT 'mood left prompt'
|
||||
() (concat "(" __mood ")" ))
|
||||
|
||||
(def CFG_FLESH_R_PROMPT 'mood right prompt'
|
||||
() 'call set-mood to change prompt')
|
||||
|
||||
(def CFG_FLESH_PROMPT_DELIMITER 'mood prompt delim'
|
||||
() '>')
|
||||
|
||||
(def set-mood 'set the little ascii face in your prompt'
|
||||
(mood) (set (q __mood) mood))
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
#!/bin/relish
|
||||
|
||||
(def __mood 'current mood' ':3')
|
||||
|
||||
(def CFG_RELISH_L_PROMPT 'mood left prompt'
|
||||
() (concat "(" __mood ")" ))
|
||||
|
||||
(def CFG_RELISH_R_PROMPT 'mood right prompt'
|
||||
() 'call set-mood to change prompt')
|
||||
|
||||
(def CFG_RELISH_PROMPT_DELIMITER 'mood prompt delim'
|
||||
() '>')
|
||||
|
||||
(def set-mood 'set the little ascii face in your prompt'
|
||||
(mood) (set (q __mood) mood))
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/relish
|
||||
#!/bin/flesh
|
||||
|
||||
(def prepend
|
||||
'takes a list and appends an element to the back of it.
|
||||
returns prepended list'
|
||||
(elem list)
|
||||
(reverse (append (reverse list) elem)))
|
||||
(reverse (append (reverse list) elem)))
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
;;; relish-mode.el --- sample major mode for editing Relish. -*- coding: utf-8; lexical-binding: t; -*-
|
||||
;;; flesh-mode.el --- Flesh -*- coding: utf-8; lexical-binding: t; -*-
|
||||
|
||||
;; Copyright © 2017, by Ava Hahn
|
||||
;; Author: Ava Hahn (ava@sunnypup.io)
|
||||
;; Copyright © 2023, by Ava Affine
|
||||
;; Author: Ava Affine (ava@sunnypup.io)
|
||||
;; Version: 1
|
||||
;; Keywords: languages
|
||||
|
||||
|
|
@ -12,7 +12,7 @@
|
|||
|
||||
;;; Code:
|
||||
|
||||
(setq relish-keywords
|
||||
(setq flesh-keywords
|
||||
(let* (
|
||||
(r-control-flow '("if" "let" "circuit" "while" "assert" "exit"))
|
||||
(r-declaration '("lambda" "q" "quote" "def" "get-doc" "set-doc" "set?"))
|
||||
|
|
@ -53,7 +53,7 @@
|
|||
(,r-userlib-regexp . 'font-lock-function-name-face)
|
||||
)))
|
||||
|
||||
(setq relish-mode-syntax-table
|
||||
(setq flesh-mode-syntax-table
|
||||
(let ((table (make-syntax-table)))
|
||||
;; string delims
|
||||
(modify-syntax-entry ?' "\"" table)
|
||||
|
|
@ -68,12 +68,12 @@
|
|||
|
||||
(define-derived-mode relish-mode
|
||||
text-mode
|
||||
"Major mode for editing Relish"
|
||||
:syntax-table relish-mode-syntax-table
|
||||
(setq font-lock-defaults '((relish-keywords))))
|
||||
"Flesh"
|
||||
:syntax-table flesh-mode-syntax-table
|
||||
(setq font-lock-defaults '((flesh-keywords))))
|
||||
|
||||
(add-to-list 'auto-mode-alist '("\\.rls\\'" . relish-mode))
|
||||
(add-to-list 'auto-mode-alist '(".relishrc" . relish-mode))
|
||||
(add-to-list 'auto-mode-alist '("\\.f\\'" . relish-mode))
|
||||
(add-to-list 'auto-mode-alist '(".fleshrc" . relish-mode))
|
||||
(provide 'relish-mode)
|
||||
|
||||
;;; relish-mode.el ends here
|
||||
;;; flesh-mode.el ends here
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/relish
|
||||
#!/bin/flesh
|
||||
|
||||
;; relish: versatile lisp shell
|
||||
;; Copyright (C) 2021 Aidan Hahn
|
||||
;; Flesh: Flexible Shell
|
||||
;; Copyright (C) 2021 Ava Affine
|
||||
;;
|
||||
;; This program is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
#!/bin/relish
|
||||
#!/bin/flesh
|
||||
|
||||
;; relish: versatile lisp shell
|
||||
;; Copyright (C) 2021 Aidan Hahn
|
||||
;; Flesh: Flexible Shell
|
||||
;; Copyright (C) 2021 Ava Affine
|
||||
;;
|
||||
;; This program is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -53,7 +53,7 @@
|
|||
refactor your program: put iterators, counters, procedurally generated code,
|
||||
and all other mutable state into a let loop.
|
||||
|
||||
A cozy script in relish is one where each root level form (or eval at repl)
|
||||
A cozy script in flesh is one where each root level form (or eval at repl)
|
||||
is self contained, and does not permanently modify any other one.
|
||||
|
||||
See the userlib tests for an easy to follow example of this.'
|
||||
Loading…
Add table
Add a link
Reference in a new issue