Commit Graph

26 Commits (5787582c2e6a69deb0a45743a7af1a7d8f238c08)

Author SHA1 Message Date
TorchedSammy 9d685ab785
feat: add hilbish.greeting 2021-12-31 13:25:53 -04:00
TorchedSammy bcc249a4bd
feat: add aliases interface (closes #87 and #86)
500th commit!
adds the `hilbish.aliases` interface
it allows you to add, delete and get all aliases

there was also a slight refactor with alias resolving in this commit,
there is a single resolve function instead of duplicate code.
with consideration this could be exported to lua side,
but i see no reason for it
2021-12-14 20:54:23 -04:00
TorchedSammy fe8372379c
fix: make user dataDir on non linux the config dir 2021-12-14 09:41:47 -04:00
TorchedSammy 2e4bea8292
refactor!: replace hilbish.xdg with hilbish.userDir
"xdg" is basically a linux specific thing and it acted linux specific also.
so replace that with a more portable and general "userDir" table

config is for the user's config directory and also defaults to xdg vars on linux.
data is a directory to store data, mostly for scripts.
on other oses beside linux, it is just the config directory for now
2021-12-13 20:13:17 -04:00
TorchedSammy b920f7d7b1
docs: change the description for the hilbish module 2021-12-13 17:32:55 -04:00
TorchedSammy c6edbc20af
style: dont explicitly set exitcode to 0 since its the default value 2021-12-07 17:27:07 -04:00
TorchedSammy 5c6310b1ca
refactor: dont export functions and types 2021-12-06 17:21:31 -04:00
TorchedSammy 2e21af4d6b
refactor: use curuser to get homedir everywhere 2021-12-01 18:31:04 -04:00
TorchedSammy 12910ba724
fix: add docs for hilbish.xdg 2021-11-25 22:24:35 -05:00
TorchedSammy 43ddab699f
feat: add in shell documentation for module properties 2021-11-22 18:59:28 -05:00
sammyette 84ec3d085d
feat: add hilbish.read function
`hilbish.read` will read input from the user, using
hilbish's line editor library (hilbiline or readline)
2021-10-30 19:53:42 -04:00
sammyette 97a6e4baf2
feat: add hilbish.interactive and hilbish.login vars
these are to check from lua if hilbish is running an interactive or
login session
2021-10-30 19:44:40 -04:00
sammyette 87fcdd3c10
fix: remove / at the end of xdg data path 2021-10-17 23:13:53 -04:00
sammyette 1e76b1501f
fix: add back dataDir field to hilbish module 2021-10-17 17:16:49 -04:00
sammyette 4dd6db54fe
fix: stop using setField wrapper 2021-10-16 15:40:16 -04:00
sammyette 3b97b22f10
feat: add hilbish.dataDir var 2021-10-16 13:51:09 -04:00
sammyette 3cafbe8c4f
docs: document `hilbish` module functions, xdg vars, and add descriptions for modules 2021-10-16 12:41:10 -04:00
L3af 400dd2944d
feat: respect xdg directories (#71)
* feat: respect xdg directories

* fix: move xdg vars to table

Co-authored-by: L3af <ohhaon@icloud.com>
2021-10-07 20:58:07 -04:00
sammyette c95b0b55be
fix: runtime errors on linux
this fixes out of bounds error since we tried to split the username
for '\' which is only valid on windows, so i added it for windows only
2021-09-25 21:39:06 -04:00
sammyette a3cc8160d3 fix: trim off hostname in %u verb for windows 2021-07-08 03:44:57 -07:00
sammyette a4dbfbf4bb
feat: add hilbish.home
`hilbish.home` is the user's home directory path
this is a cross platform variable that works instead of using
`$HOME` (which isnt set in windows cmd, i think)
2021-06-11 21:49:28 -04:00
sammyette af4b4b2ae0
feat: add hilbish.cwd function 2021-05-27 19:06:17 -04:00
sammyette 12828d197a
feat: add hilbish.flag function
this checks if a certain flag has been passed to hilbish
2021-05-16 18:10:46 -04:00
sammyette ef1ced4a04
refactor: make `hilbish` an already required module and add run function
idk how to explain this man
in code `hilbish` is now a module, which can also be required like
others. but it is already a global export as the variable of the same
name.
also
2021-05-16 17:13:28 -04:00
sammyette c6aa5fa387
fix: remove unneeded struct tag 2021-05-16 16:18:46 -04:00
sammyette e29ba6a0d5
feat!: move username and version access to hilbish table
instead of having ugly `_user` and `_ver` variables,
`hilbish.user` and `hilbish.version` is used
2021-05-16 15:53:21 -04:00