Happy birthday Hilbish! As of last month, Hilbish is now 2 years old.
Unfortunately I missed the official date, but I will still make a more
focused post on the date (19st).
I decided to fix up this website and Hilbish's logo, so that can
-be thought of as something for the 2 years milestone?
Logo
+be thought of as something for the 2 years milestone?
Logo
Hilbish's old logo was.. not that good. It definitely functioned
as a logo, but the yellow part of it looked ugly (sorry old logo).
You would have definitely seen the new logo, since it is currently
@@ -13,13 +13,13 @@ in use on the navigation bar and footer. Here it is in a bigger view:
# Website
Ever since this website was first made, from the release of v2.0, it has
-been doing it's job of being a website good enough, but there were a few issues.
Padding
+been doing it's job of being a website good enough, but there were a few issues.
Padding
Padding is very important! The edges of your screen need space to do nothing,
after all. On mobile or screens small enough, there would not be enough space
for the auto margin to fill, and since there was no padding besides that,
it means things would look a bit cramped. This was simple to fix.
Here it is before:
and after:
-
Docs Navigation
+
Docs Navigation
On the docs page, the pages are on the left on desktop. Since
phones are too small to have this content on the side, it stays at the top.
This is a bit counter intuitive since it brings in extra scrolling
@@ -28,8 +28,8 @@ was not hidden by default. So a few improvements were made:
- Make the doc navigation hidden by default on mobile, just like site wide navigation
- Make doc navigation have the same look as site wide navigation
Here's a before:
and after:
-
Looks a lot better now.
Other Changes
+
Looks a lot better now.
Other Changes
If you haven't noticed, I have made other changes to the website.
This includes:
- Borders! Something this simple makes the website look a lot better, especially on mobile.
-- More padding and margin everywhere. Home, doc pages, blog post listing.
\ No newline at end of file
+- More padding and margin everywhere. Home, doc pages, blog post listing.
\ No newline at end of file
diff --git a/versions/new-website/blog/v2.0-release/index.html b/versions/new-website/blog/v2.0-release/index.html
index e73c475b..8efb1a9b 100644
--- a/versions/new-website/blog/v2.0-release/index.html
+++ b/versions/new-website/blog/v2.0-release/index.html
@@ -1,9 +1,9 @@
-Hilbish
Hilbish v2.0 has been released!
Well actually, it was released a week ago, but I only wrote this
Hilbish blog after that.
This is a *big* release, coming 9 months after the previous v1.2.0 and
featuring over 40+ bug fixes and tons of new features and enhancements, so
-let's see what is in this release.
Documentation
+let's see what is in this release.
Documentation
When querying about the problems people have with Hilbish, one of the
issues was its poor documentation. Hilbish had plain text, autogenerated
documentation which only covered the module functions (bait, hilbish,
@@ -11,31 +11,31 @@ commander, etc.) and did not include the interfaces (hilbish.jobs and all that).
I have tried to improve this by working on documenting all the
interfaces (except for some functions of hilbish.runner, that's hard to do)
and made the documentation markdown for use on this website. This means
-that users can look at documentation here or with the doc command.
Hopefully this addresses documentation complaints, and if not, please open an issue.
Main Bug Fixes
+that users can look at documentation here or with the doc command.
Hopefully this addresses documentation complaints, and if not, please open an issue.
Main Bug Fixes
As this is a piece of software with no unit testing that is maintained by me alone,
there is gonna be either some bug or something that I overlooked when
making a change. I make a lot of mistakes. There's also the other fact that
sometimes there's just bugs for any other reasosn. Good thing I fixed
-more than 40 of those bugs in this release!
Readline Bug Fixes
+more than 40 of those bugs in this release!
Readline Bug Fixes
The pure Go readline library is good in some ways and bad in others.
A good portion of the bug fixes are for the readline library, and also
related to text input with east asian characters and the like (Korean, Japanese,
etc.)
A few of the fixes (and additions) include:
Fixing various crashes, including when there is a "stray" newline at the end of text
Grid completion menu causing spam and duplicate text when there are items longer than
the terminal and/or contain Japanese or other characters.
- Cursor positioning with CJK characters
-- Adding new keybinds and fixing others
Other fixes
+- Adding new keybinds and fixing others
Other fixes
There are a lot more fixes, even more than the ones listed here, but these are the main ones:
- Don't put alias expanded command in history (I've fixed this 5 times now....)
- Handle stdin being nonblocking
- - Completion related fixes, like showing the full name, completing files with spaces
Breaking changes
+ - Completion related fixes, like showing the full name, completing files with spaces
Breaking changes
This release is a major version bump not only because there are tons of fixes, but because
there are breaking changes. This means that there are some changes done which would
-cause errors with an old user config (breaking).
Lua 5.4
+cause errors with an old user config (breaking).
Lua 5.4
The most important is the use of a new Lua VM library. Previously, Hilbish
used gopher-lua, which implements Lua 5.1. This has been changed to
golua, which implements Lua 5.4.
Moving from 5.1 to 5.4 does have breaking changes even if it doesn't seem like it,
-and since these are different Lua implementations, there may be some differences there too.
Userdata
+and since these are different Lua implementations, there may be some differences there too.
Userdata
Previously, objects such as jobs or timers were represented by tables.
-This has been changed to userdata to make more sense.
Other changes
+This has been changed to userdata to make more sense.
Other changes
Runner functions are now required to return a table.
It can (at the moment) have 4 variables:
- input (user input)
@@ -46,17 +46,17 @@ User input has been added to the return to account for runners wanting to
prompt for continued input, and to add it properly to history. continue
got added so that it would be easier for runners to get continued input
without having to actually handle it at all.
The MacOS config paths now match Linux, since it makes more sense for
-a program like Hilbish.
The Hilbish greeting is now an opt, and is printed by default.
Feature Additions
+a program like Hilbish.
The Hilbish greeting is now an opt, and is printed by default.
Feature Additions
Besides fixes and changes, this release also includes a good portion of
new features! Users can now add handlers for syntax highlighting and
inline hinting.
Some new hooks have been added, like hilbish.cancel and hilbish.init.
You can look at all the hooks via the doc hooks command
Job management functions have also been added. You can now put jobs in the
foreground/background and disown them via the expected commands and also
-via the Lua API.
The hilbish.timers API interface was also added in this release!
Closing Off
+via the Lua API.
The hilbish.timers API interface was also added in this release!
Closing Off
Hilbish has gone from something small and simple for myself to a slightly
advanced shell with a decent amount of features, and a few users. It
still hasn't reached levels of other alt shells in regards to literally
everything, but the goal is to get there!
If you want to check the FULL changelog, you can do so here.
This v2.0 release marks an advancement in Hilbish (and also how long
one of my projects hasn't died) and I hope it can advance even further.
Thanks for reading, and I'll be back for the v2.1 release notes, or maybe
-something else in between.
\ No newline at end of file
+something else in between.
\ No newline at end of file
diff --git a/versions/new-website/blog/v2.1-release/index.html b/versions/new-website/blog/v2.1-release/index.html
index a1e7c7c4..5fdd1cfa 100644
--- a/versions/new-website/blog/v2.1-release/index.html
+++ b/versions/new-website/blog/v2.1-release/index.html
@@ -1,36 +1,36 @@
-Hilbish
> The release with full changelogs and prebuilt binaries can be
seen at the v2.1.0
tag.
Oh look! A new release of Hilbish! This time is the v2.1 release,
with a small amount of features and mainly documentation changes and
-bug fixes.
Documentation
+bug fixes.
Documentation
There have been a few documentation enhancements for this release.
This includes:
- Adding the return types for all functions that need them
- Documenting Hilbish types like job objects and timers properly.
They now have a separate heading and listing of properties and methods.
-- Fixing outdated documentation
Features
Sinks
+- Fixing outdated documentation
Features
Sinks
A major addition is the new "sink" type for commanders to write
their output to. This was the solution to pipes and other shell
operators not working with builtins. If you wrote a commander
-and made it print, use sinks.out:write instead.
doc command
Since API documentation has been moved to an API folder and also includes
interfaces, a change has been made to get the module name from the
passed from the requested page. This means that
-doc api hilbish hilbish.jobs is now shortened to doc api hilbish.jobs
Bug Fixes
+doc api hilbish hilbish.jobs is now shortened to doc api hilbish.jobs
Bug Fixes
Small release, small amount of bug fixes. Even though, this is the main
-part of this release.
Completions and Symlinks
+part of this release.
Completions and Symlinks
Previously Hilbish completions did not work with symlinks properly.
This can be tested in the previous 2.0 release by attempting to
path complete to /bin. Since this is (or can be?) a symlink to
/usr/bin, it was not marked as a directory and therefore did not
-automatically add the ending slash. This has been fixed.
Segfaults
+automatically add the ending slash. This has been fixed.
Segfaults
I found that when I updated my terminal of choice ([Tym]) for the new
daemon feature, Hilbish would sometimes segfault on startup. This is due
to it getting a resize event on startup while bait was not initialized
-yet.
API Fixes
+yet.
API Fixes
- The hilbish.which function works with aliases.
- hilbish.completion.files and hilbish.completion.bins will no longer
-cause a panic with all empty arguments passed.
Next Release
+cause a panic with all empty arguments passed.
Next Release
Stay tuned for the v2.2 release, which will have a bigger set of features
-and maybe some more bug fixes!
\ No newline at end of file
+and maybe some more bug fixes!
\ No newline at end of file
diff --git a/versions/new-website/blog/v2.1.1-release/index.html b/versions/new-website/blog/v2.1.1-release/index.html
index fbb2ab72..75301aa9 100644
--- a/versions/new-website/blog/v2.1.1-release/index.html
+++ b/versions/new-website/blog/v2.1.1-release/index.html
@@ -1,18 +1,18 @@
-Hilbish
> The release with full changelogs and prebuilt binaries can be
seen at the v2.1.1
tag.
Welcome to a fresh new release of Hilbish! Some people (or none) may be awaiting
the long coming v2.2 release with lots of features, but I needed to push
-out this little bug fix (wink) release.
Bug Fixes
Validation checks for command input
+out this little bug fix (wink) release.
Bug Fixes
Validation checks for command input
When running this version, you may have noticed an odd message that sometimes
comes up when running commands. This is from the new TMOLI42SH
-(The Meaning of Life is 42 String Hash) input validation scheme.
Improved runtime code
+(The Meaning of Life is 42 String Hash) input validation scheme.
Improved runtime code
Commands now have a chance of taking exactly 2-3s ~~more~~ less time of running due to
-improvements in the code for shell runners!!!!!
Validate lua code
+improvements in the code for shell runners!!!!!
Validate lua code
Hilbish already threw an error when Lua code was not valid in syntax, but there was the
need for an extra validation scheme (called OpTTCLC - Opinion based Turing Test to Check Lua Code)
-which results in less time wasted running invalid and TERRIBLE Lua code.
Features
-There is only 1 new feature in this glorious release.
Fix your mistakes for the future
-If you run a command that does not exist, Hilbish will say goodbye.
Closing
+which results in less time wasted running invalid and TERRIBLE Lua code.
Features
+There is only 1 new feature in this glorious release.
Fix your mistakes for the future
+If you run a command that does not exist, Hilbish will say goodbye.
Closing
Hope you enjoy this new release! It took a lot of effort to create this new version
-while I was busy doing completely nothing. :)))
\ No newline at end of file
+while I was busy doing completely nothing. :)))
\ No newline at end of file
diff --git a/versions/new-website/blog/v2.1.2-release/index.html b/versions/new-website/blog/v2.1.2-release/index.html
index 922d3ad4..8aee419c 100644
--- a/versions/new-website/blog/v2.1.2-release/index.html
+++ b/versions/new-website/blog/v2.1.2-release/index.html
@@ -1,6 +1,6 @@
-Hilbish
> The release with full changelogs and prebuilt binaries can be
seen at the v2.1.2
tag.
This release reverts the April Fool's code additions in v2.1.1. It is
functionally equal to v2.1.0. Nice!
A real release will come possibly in a few days or next week, so stay tuned for
-the good and feature-filled release of v2.2!
\ No newline at end of file
+the good and feature-filled release of v2.2!
\ No newline at end of file
diff --git a/versions/new-website/blog/v2.2-release/index.html b/versions/new-website/blog/v2.2-release/index.html
index 7ad81fd8..a89b9ed2 100644
--- a/versions/new-website/blog/v2.2-release/index.html
+++ b/versions/new-website/blog/v2.2-release/index.html
@@ -1,10 +1,10 @@
-Hilbish
> The release with full changelogs and prebuilt binaries can be
seen at the v2.2.0
tag.
Welcome to a very long awaited release of Hilbish, and on Christmas. Just think
of it as a long preparing, late Christmas gift. :)
This release does not contain a whole lot of changes, but it is a new
-release with enhancements and bug fixes!
Documentation
+release with enhancements and bug fixes!
Documentation
As is a trend, the documentation has been improved by ONE HUNDRED TIMES.
Okay, not quite, but they've definitely been given an uplift.
Everything has been rewritten, new documentation has been added to both
@@ -17,12 +17,12 @@ The first new added feature is the Greenhouse pager! It is a library and
command accessible via greenhouse. It will have better integration with
Hilbish things, like notifications and can be used as a base for displaying
multi-line text output instead of paging to less. The usage of Greenhouse is
-more efficient and better in Hibish!
Notifications
+more efficient and better in Hibish!
Notifications
Wait... notifications? Yes! All new in the 2.2 release is a generic notification
interface for things in Hilbish to alert the user of things going on. Stuff like
-background jobs finishing, simple alarms, actual messages, whatever you like.
Fuzzy Searching
+background jobs finishing, simple alarms, actual messages, whatever you like.
Fuzzy Searching
Users can now use fuzzy search for command history and completion search.
-Enable it with hilbish.opts.fuzzy = true!
Smaller Enhancements
+Enable it with hilbish.opts.fuzzy = true!
Smaller Enhancements
Did you know of the cdr command? I personally don't use it, but I've made
it look slightly better for ease of use. That simple change is adding the indexes
next to the directory so you'll know to type cdr 2.
Users can now add aliases with numbered substitutions. In shell script,
@@ -31,7 +31,7 @@ just aliases. A simple example: run normally there would be a space after.
Simple fix:
lua
hilbish.alias('run', 'nix run nixpkgs#%1')
-
Rejoice!
Bug Fixes
+
Rejoice!
Bug Fixes
There are a small amount of bug fixes but they're still fixes!
In some cases Hilbish will panic if:
- Alias resolution results in something empty
- A user does not return a table in a runner functions
@@ -39,8 +39,8 @@ These are both fixed.
An infinite loop has been patched out if someone nav
having any prior history. Imagine pressing the up key on a fresh Hilbish
install and you shell no longer working... that's gone now.
Something else that's gone... is still Windows support, but I added a fix
which will make file completion work now. Job management commands work as
-well now too due to an oversight when changing up the job functions.
Towards v2.3
+well now too due to an oversight when changing up the job functions.
Towards v2.3
For the next release, I'm hoping that it won't take as long to deliver on
what is realistically a small amount of changes. So v2.3 will be coming
in a short time with some good changes, promise! See you in the
-next blog post.
\ No newline at end of file
+next blog post.
\ No newline at end of file
diff --git a/versions/new-website/blog/v2.3-release/index.html b/versions/new-website/blog/v2.3-release/index.html
index c6096190..a3ed8045 100644
--- a/versions/new-website/blog/v2.3-release/index.html
+++ b/versions/new-website/blog/v2.3-release/index.html
@@ -1,9 +1,9 @@
-Hilbish
> The release with full changelogs and prebuilt binaries can be
seen at the v2.3.0
tag.
Hilbish v2.3 has now been released! This is small feature and bug fix release
which took a while to cme ut since I took a long break from programming in general.
-The next release will be great, so stay tuned for that.
Features
Pipes (via Lua)
+The next release will be great, so stay tuned for that.
Features
Pipes (via Lua)
Commands can now be piped to each other via the Lua API with the hilbish.run
function and an fs.pipe.
Here is a minimal example of the new usage which allows users to now pipe commands
directly via Lua functions:
@@ -18,10 +18,10 @@ hilbish.run('ls -l', {
stdin = pr
})
This also means it's easier to make commands output to any stream output,
-including in commanders.
Bug Fixes
+including in commanders.
Bug Fixes
- Commanders can now be cancelled with Ctrl-C, which means if they froze for some reason
they can now be exited.
- The shell script interpreter now keeps its environment, and this also fixes the
current working directory being wrong with some commands.
- Some greenhouse bugs have been fixed, like randomly appearing when resizing the terminal
-and some text attributes like color appearing where they weren't supposed to.
\ No newline at end of file
+and some text attributes like color appearing where they weren't supposed to.
\ No newline at end of file
diff --git a/versions/new-website/blog/welcome/index.html b/versions/new-website/blog/welcome/index.html
index 3c6a1351..27b58e93 100644
--- a/versions/new-website/blog/welcome/index.html
+++ b/versions/new-website/blog/welcome/index.html
@@ -1,3 +1,3 @@
-Hilbish
Hello! Welcome to the Hilbish blog. This will mainly contain release
+announcements and some other things relating to Hilbish (development).
\ No newline at end of file
diff --git a/versions/new-website/docs/api/bait/index.html b/versions/new-website/docs/api/bait/index.html
index 51d7c181..5a1f8724 100644
--- a/versions/new-website/docs/api/bait/index.html
+++ b/versions/new-website/docs/api/bait/index.html
@@ -1,5 +1,5 @@
-Hilbish
Bait is the event emitter for Hilbish. Much like Node.js and
its events system, many actions in Hilbish emit events.
Unlike Node.js, Hilbish events are global. So make sure to
pick a unique name!
Usage of the Bait module consists of userstanding
@@ -14,7 +14,7 @@ bait.catch('command.exit', function(code)
doNotifyPrompt()
end)
What this does is, whenever the command.exit event is thrown,
-this function will set the user prompt.
Functions
+this function will set the user prompt.
Functions
@@ -39,16 +39,16 @@ this function will set the user prompt.
Functions
+
Functions
bait.catch(name, cb)
-
Catches an event. This function can be used to act on events.
Parameters
string*name*
+
Catches an event. This function can be used to act on events.
Parameters
string*name*
The name of the hook.
function*cb*
-The function that will be called when the hook is thrown.
Example
bait.catch('hilbish.exit', function()
+The function that will be called when the hook is thrown.
Catches an event, but only once. This will remove the hook immediately after it runs for the first time.
Parameters
string*name*
+
Catches an event, but only once. This will remove the hook immediately after it runs for the first time.
Parameters
string*name*
The name of the event
function*cb*
The function that will be called when the event is thrown.
@@ -67,7 +67,7 @@ bait.hooks(name) -> table
-
Returns a table of functions that are hooked on an event with the corresponding name.
Parameters
string*name*
+
Returns a table of functions that are hooked on an event with the corresponding name.
Parameters
string*name*
The name of the hook
@@ -77,9 +77,9 @@ bait.release(name, catcher)
Removes the catcher for the event with name.
For this to work, catcher has to be the same function used to catch
-an event, like one saved to a variable.
Parameters
string*name*
+an event, like one saved to a variable.
Parameters
string*name*
Name of the event the hook is on
function*catcher*
-Hook function to remove
Example
local hookCallback = function() print 'hi' end
+Hook function to remove
Example
local hookCallback = function() print 'hi' end
bait.catch('event', hookCallback)
@@ -93,12 +93,12 @@ bait.throw(name, ...args)
-
Throws a hook with name with the provided args.
Parameters
string*name*
+
Throws a hook with name with the provided args.
Parameters
string*name*
The name of the hook.
any*args* (This type is variadic. You can pass an infinite amount of parameters with this type.)
-The arguments to pass to the hook.
Example
bait.throw('greeting', 'world')
+The arguments to pass to the hook.
Example
bait.throw('greeting', 'world')
-- This can then be listened to via
bait.catch('gretting', function(greetTo)
print('Hello ' .. greetTo)
end)
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/versions/new-website/docs/api/commander/index.html b/versions/new-website/docs/api/commander/index.html
index 1bd6375a..b98c9820 100644
--- a/versions/new-website/docs/api/commander/index.html
+++ b/versions/new-website/docs/api/commander/index.html
@@ -1,5 +1,5 @@
-Hilbish
Commander is the library which handles Hilbish commands. This makes
the user able to add Lua-written commands to their shell without making
a separate script in a bin folder. Instead, you may simply use the Commander
library in your Hilbish config.
local commander = require 'commander'
@@ -17,7 +17,7 @@ In the future, sinks.inout is standard output.
This is usually where command output should go.
- err is standard error.
-This sink is for writing errors, as the name would suggest.
Functions
+This sink is for writing errors, as the name would suggest.
Functions
@@ -34,14 +34,14 @@ This sink is for writing errors, as the name would suggest.
Functions
+
Functions
commander.deregister(name)
-
Removes the named command. Note that this will only remove Commander-registered commands.
Parameters
string*name*
+
Removes the named command. Note that this will only remove Commander-registered commands.
Parameters
string*name*
Name of the command to remove.
@@ -50,9 +50,9 @@ commander.register(name, cb)
Adds a new command with the given name. When Hilbish has to run a command with a name,
-it will run the function providing the arguments and sinks.
Parameters
string*name*
+it will run the function providing the arguments and sinks.
Parameters
string*name*
Name of the command
function*cb*
-Callback to handle command invocation
Example
-- When you run the command `hello` in the shell, it will print `Hello world`.
+Callback to handle command invocation
Example
-- When you run the command `hello` in the shell, it will print `Hello world`.
-- If you run it with, for example, `hello Hilbish`, it will print 'Hello Hilbish'
commander.register('hello', function(args, sinks)
local name = 'world'
@@ -68,4 +68,4 @@ commander.registry() -> table
Returns all registered commanders. Returns a list of tables with the following keys:
-- exec: The function used to run the commander. Commanders require args and sinks to be passed.
Parameters
This function has no parameters.
\ No newline at end of file
+- exec: The function used to run the commander. Commanders require args and sinks to be passed.
Parameters
This function has no parameters.
\ No newline at end of file
diff --git a/versions/new-website/docs/api/fs/index.html b/versions/new-website/docs/api/fs/index.html
index 15e22d6b..7d2287e5 100644
--- a/versions/new-website/docs/api/fs/index.html
+++ b/versions/new-website/docs/api/fs/index.html
@@ -1,7 +1,7 @@
-Hilbish
The fs module provides filesystem functions to Hilbish. While Lua's standard
library has some I/O functions, they're missing a lot of the basics. The fs
-library offers more functions and will work on any operating system Hilbish does.
Functions
+library offers more functions and will work on any operating system Hilbish does.
Functions
@@ -46,7 +46,7 @@ library offers more functions and will work on any operating system Hilbish does
-
Static module fields
+
Static module fields
@@ -55,7 +55,7 @@ library offers more functions and will work on any operating system Hilbish does
Match all files based on the provided pattern.
-For the syntax' refer to Go's filepath.Match function: https://pkg.go.dev/path/filepath#Match
Parameters
string*pattern*
-Pattern to compare files with.
Example
--[[
+For the syntax' refer to Go's filepath.Match function: https://pkg.go.dev/path/filepath#Match
Parameters
string*pattern*
+Pattern to compare files with.
Example
--[[
Within a folder that contains the following files:
a.txt
init.lua
@@ -115,8 +115,8 @@ fs.join(...path) -> string
-
Takes any list of paths and joins them based on the operating system's path separator.
Parameters
string*path* (This type is variadic. You can pass an infinite amount of parameters with this type.)
-Paths to join together
Example
-- This prints the directory for Hilbish's config!
+
Takes any list of paths and joins them based on the operating system's path separator.
Parameters
string*path* (This type is variadic. You can pass an infinite amount of parameters with this type.)
+Paths to join together
Example
-- This prints the directory for Hilbish's config!
print(fs.join(hilbish.userDir.config, 'hilbish'))
-- -> '/home/user/.config/hilbish' on Linux
@@ -127,9 +127,9 @@ fs.mkdir(name, recursive)
Creates a new directory with the provided name.
-With recursive, mkdir will create parent directories.
Parameters
string*name*
+With recursive, mkdir will create parent directories.
Parameters
string*name*
Name of the directory
boolean*recursive*
-Whether to create parent directories for the provided name
Example
-- This will create the directory foo, then create the directory bar in the
+Whether to create parent directories for the provided name
Example
-- This will create the directory foo, then create the directory bar in the
-- foo directory. If recursive is false in this case, it will fail.
fs.mkdir('./foo/bar', true)
@@ -140,14 +140,14 @@ fs.fpipe() -> File, File
Returns a pair of connected files, also known as a pipe.
-The type returned is a Lua file, same as returned from io functions.
Parameters
This function has no parameters.
+The type returned is a Lua file, same as returned from io functions.
Parameters
This function has no parameters.
fs.readdir(path) -> table[string]
-
Returns a list of all files and directories in the provided path.
Parameters
string*dir*
+
Returns a list of all files and directories in the provided path.
Parameters
string*dir*
fs.stat(path) -> {}
@@ -159,7 +159,7 @@ The returned table contains the following values:
name (string) - Name of the path
size (number) - Size of the path in bytes
mode (string) - Unix permission mode in an octal format string (with leading 0)
-isDir (boolean) - If the path is a directory
Parameters
string*path*
Example
local inspect = require 'inspect'
+isDir (boolean) - If the path is a directory
Parameters
string*path*
Example
local inspect = require 'inspect'
local stat = fs.stat '~'
print(inspect(stat))
@@ -172,4 +172,4 @@ Would print the following:
size = 12288
}
]]--
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/versions/new-website/docs/api/hilbish/index.html b/versions/new-website/docs/api/hilbish/index.html
index c60b50b4..6c1ac741 100644
--- a/versions/new-website/docs/api/hilbish/index.html
+++ b/versions/new-website/docs/api/hilbish/index.html
@@ -1,6 +1,5 @@
-Hilbish
@@ -69,57 +68,16 @@ interfaces and functions which directly relate to shell functionality.
-
Static module fields
-
-
-
-
ver
-
The version of Hilbish
-
-
-
goVersion
-
The version of Go that Hilbish was compiled with
-
-
-
user
-
Username of the user
-
-
-
host
-
Hostname of the machine
-
-
-
dataDir
-
Directory for Hilbish data files, including the docs and default modules
-
-
-
interactive
-
Is Hilbish in an interactive shell?
-
-
-
login
-
Is Hilbish the login shell?
-
-
-
vimMode
-
Current Vim input mode of Hilbish (will be nil if not in Vim input mode)
-
-
-
exitCode
-
Exit code of the last executed command
-
-
-
-
Functions
+
Functions
hilbish.alias(cmd, orig)
-
Sets an alias, with a name of cmd to another command.
Parameters
string*cmd*
+
Sets an alias, with a name of cmd to another command.
Parameters
string*cmd*
Name of the alias
string*orig*
-Command that will be aliased
Example
-- With this, "ga file" will turn into "git add file"
+Command that will be aliased
Example
-- With this, "ga file" will turn into "git add file"
hilbish.alias('ga', 'git add')
-- Numbered substitutions are supported here!
@@ -132,8 +90,8 @@ hilbish.appendPath(dir)
-
Appends the provided dir to the command path ($PATH)
Parameters
string|table*dir*
-Directory (or directories) to append to path
Example
hilbish.appendPath '~/go/bin'
+
Appends the provided dir to the command path ($PATH)
Parameters
string|table*dir*
+Directory (or directories) to append to path
Example
hilbish.appendPath '~/go/bin'
-- Will add ~/go/bin to the command path.
-- Or do multiple:
@@ -152,7 +110,7 @@ hilbish.complete(scope, cb)
A scope is expected to be command.<cmd>,
replacing <cmd> with the name of the command (for example command.git).
The documentation for completions, under Features/Completions or doc completions
-provides more details.
Parameters
string*scope*
function*cb*
Example
-- This is a very simple example. Read the full doc for completions for details.
+provides more details.
Parameters
string*scope*
function*cb*
Example
-- This is a very simple example. Read the full doc for completions for details.
hilbish.complete('command.sudo', function(query, ctx, fields)
if #fields == 0 then
-- complete for commands
@@ -182,7 +140,7 @@ hilbish.cwd() -> string
-
Puts fn in a Goroutine.
This can be used to run any function in another thread at the same time as other Lua code.
*NOTE: THIS FUNCTION MAY CRASH HILBISH IF OUTSIDE VARIABLES ARE ACCESSED.*
-*This is a limitation of the Lua runtime.*
Parameters
function*fn*
+*This is a limitation of the Lua runtime.*
Parameters
function*fn*
hilbish.highlighter(line)
@@ -211,9 +169,11 @@ hilbish.highlighter(line)
This is mainly for syntax highlighting, but in reality could set the input
of the prompt to display anything. The callback is passed the current line
and is expected to return a line that will be used as the input display.
-Note that to set a highlighter, one has to override this function.
Parameters
string*line*
Example
--This code will highlight all double quoted strings in green.
+Note that to set a highlighter, one has to override this function.
Parameters
string*line*
Example
--This code will highlight all double quoted strings in green.
function hilbish.highlighter(line)
- return line:gsub('"%w+"', function(c) return lunacolors.green(c) end)
+
+ return line:gsub('"%w+"', function(c) return lunacolors.green(c) end)
+
end
@@ -226,8 +186,8 @@ hilbish.hinter(line, pos)
determine what text to use as an inline hint. It is passed the current
line and cursor position. It is expected to return a string which is used
as the text for the hint. This is by default a shim. To set hints,
-override this function with your custom handler.
Parameters
string*line*
number*pos*
-Position of cursor in line. Usually equals string.len(line)
Example
-- this will display "hi" after the cursor in a dimmed color.
+override this function with your custom handler.
Parameters
string*line*
number*pos*
+Position of cursor in line. Usually equals string.len(line)
Example
-- this will display "hi" after the cursor in a dimmed color.
function hilbish.hinter(line, pos)
return 'hi'
end
@@ -240,7 +200,7 @@ hilbish.inputMode(mode)
Sets the input mode for Hilbish's line reader.
emacs is the default. Setting it to vim changes behavior of input to be
-Vim-like with modes and Vim keybinds.
Parameters
string*mode*
+Vim-like with modes and Vim keybinds.
Runs the cb function every specified amount of time.
-This creates a timer that ticking immediately.
Parameters
function*cb*
number*time*
+This creates a timer that ticking immediately.
Parameters
function*cb*
number*time*
Time in milliseconds.
@@ -258,7 +218,7 @@ hilbish.multiprompt(str)
Changes the text prompt when Hilbish asks for more input.
-This will show up when text is incomplete, like a missing quote
Parameters
string*str*
Example
--[[
+This will show up when text is incomplete, like a missing quote
Parameters
string*str*
Example
--[[
imagine this is your text input:
user ~ ∆ echo "hey
@@ -280,7 +240,7 @@ hilbish.prependPath(dir)
-
Prepends dir to $PATH.
Parameters
string*dir*
+
Prepends dir to $PATH.
Parameters
string*dir*
hilbish.prompt(str, typ)
@@ -292,8 +252,8 @@ There are a few verbs that can be used in the prompt text.
These will be formatted and replaced with the appropriate values.
%d - Current working directory
%u - Name of current user
-%h - Hostname of device
Parameters
string*str*
string*typ?*
-Type of prompt, being left or right. Left by default.
Example
-- the default hilbish prompt without color
+%h - Hostname of device
Parameters
string*str*
string*typ?*
+Type of prompt, being left or right. Left by default.
Example
-- the default hilbish prompt without color
hilbish.prompt '%u %d ∆'
-- or something of old:
hilbish.prompt '%u@%h :%d $'
@@ -307,7 +267,7 @@ hilbish.read(prompt) -> input (string)
Read input from the user, using Hilbish's line editor/input reader.
This is a separate instance from the one Hilbish actually uses.
-Returns input, will be nil if Ctrl-D is pressed, or an error occurs.
Parameters
string*prompt?*
+Returns input, will be nil if Ctrl-D is pressed, or an error occurs.
Parameters
string*prompt?*
Text to print before input, can be empty.
Executed the cb function after a period of time.
-This creates a Timer that starts ticking immediately.
Parameters
function*cb*
number*time*
+This creates a Timer that starts ticking immediately.
Parameters
function*cb*
number*time*
Time to run in milliseconds.
@@ -325,5 +285,5 @@ hilbish.which(name) -> string
Checks if name is a valid command.
-Will return the path of the binary, or a basename if it's a commander.
Parameters
string*name*
Types
Sink
A sink is a structure that has input and/or output to/from a desination.
Methods
autoFlush(auto)
Sets/toggles the option of automatically flushing output.
-A call with no argument will toggle the value.
flush()
Flush writes all buffered input to the sink.
read() -> string
Reads a liine of input from the sink.
readAll() -> string
Reads all input from the sink.
write(str)
Writes data to a sink.
writeln(str)
Writes data to a sink with a newline at the end.
\ No newline at end of file
+Will return the path of the binary, or a basename if it's a commander.
Parameters
string*name*
Types
Sink
A sink is a structure that has input and/or output to/from a desination.
Methods
autoFlush(auto)
Sets/toggles the option of automatically flushing output.
+A call with no argument will toggle the value.
flush()
Flush writes all buffered input to the sink.
read() -> string
Reads a liine of input from the sink.
readAll() -> string
Reads all input from the sink.
write(str)
Writes data to a sink.
writeln(str)
Writes data to a sink with a newline at the end.
\ No newline at end of file
diff --git a/versions/new-website/docs/api/index.html b/versions/new-website/docs/api/index.html
index 413e5eea..fb09708d 100644
--- a/versions/new-website/docs/api/index.html
+++ b/versions/new-website/docs/api/index.html
@@ -1,3 +1,3 @@
-Hilbish
Welcome to the API documentation for Hilbish. This documents Lua functions
+provided by Hilbish.
\ No newline at end of file
diff --git a/versions/new-website/docs/api/readline/index.html b/versions/new-website/docs/api/readline/index.html
new file mode 100644
index 00000000..c6e7fe05
--- /dev/null
+++ b/versions/new-website/docs/api/readline/index.html
@@ -0,0 +1,22 @@
+
+Hilbish
The readline module is responsible for reading input from the user.
+The readline module is what Hilbish uses to read input from the user,
+including all the interactive features of Hilbish like history search,
+syntax highlighting, everything. The global Hilbish readline instance
+is usable at hilbish.editor.
Deletes characters in the line by the given amount.
getLine() -> string
Returns the current input line.
getVimRegister(register) -> string
Returns the text that is at the register.
insert(text)
Inserts text into the Hilbish command line.
log(text)
Prints a message before the prompt without it being interrupted by user input.
read() -> string
Reads input from the user.
getChar() -> string
Reads a keystroke from the user. This is in a format of something like Ctrl-L.
setVimRegister(register, text)
Sets the vim register at register to hold the passed text.
\ No newline at end of file
diff --git a/versions/new-website/docs/api/snail/index.html b/versions/new-website/docs/api/snail/index.html
index 2ce1b24e..d7dc6993 100644
--- a/versions/new-website/docs/api/snail/index.html
+++ b/versions/new-website/docs/api/snail/index.html
@@ -1,7 +1,7 @@
-Hilbish
The snail library houses Hilbish's Lua wrapper of its shell script interpreter.
It's not very useful other than running shell scripts, which can be done with other
-Hilbish functions.
Functions
+Hilbish functions.
Functions
@@ -10,13 +10,13 @@ Hilbish functions.
Functions
+
Functions
snail.new() -> @Snail
-
Creates a new Snail instance.
Parameters
This function has no parameters.
Types
Snail
A Snail is a shell script interpreter instance.
Methods
dir(path)
Changes the directory of the snail instance.
+
Creates a new Snail instance.
Parameters
This function has no parameters.
Types
Snail
A Snail is a shell script interpreter instance.
Methods
dir(path)
Changes the directory of the snail instance.
The interpreter keeps its set directory even when the Hilbish process changes
-directory, so this should be called on the hilbish.cd hook.
run(command, streams)
Runs a shell command. Works the same as hilbish.run, but only accepts a table of streams.
\ No newline at end of file
+directory, so this should be called on the hilbish.cd hook.
run(command, streams)
Runs a shell command. Works the same as hilbish.run, but only accepts a table of streams.
\ No newline at end of file
diff --git a/versions/new-website/docs/api/terminal/index.html b/versions/new-website/docs/api/terminal/index.html
index 1ddc3ed2..d19f3962 100644
--- a/versions/new-website/docs/api/terminal/index.html
+++ b/versions/new-website/docs/api/terminal/index.html
@@ -1,5 +1,5 @@
-Hilbish
The terminal library is a simple and lower level library for certain terminal interactions.
Functions
@@ -20,28 +20,28 @@
-
Functions
+
Functions
terminal.restoreState()
-
Restores the last saved state of the terminal
Parameters
This function has no parameters.
+
Restores the last saved state of the terminal
Parameters
This function has no parameters.
terminal.saveState()
-
Saves the current state of the terminal.
Parameters
This function has no parameters.
+
Saves the current state of the terminal.
Parameters
This function has no parameters.
terminal.setRaw()
-
Puts the terminal into raw mode.
Parameters
This function has no parameters.
+
Puts the terminal into raw mode.
Parameters
This function has no parameters.
terminal.size()
@@ -49,4 +49,4 @@ terminal.size()
Gets the dimensions of the terminal. Returns a table with width and height
-NOTE: The size refers to the amount of columns and rows of text that can fit in the terminal.
Parameters
This function has no parameters.
\ No newline at end of file
+NOTE: The size refers to the amount of columns and rows of text that can fit in the terminal.
Parameters
This function has no parameters.
\ No newline at end of file
diff --git a/versions/new-website/docs/api/yarn/index.html b/versions/new-website/docs/api/yarn/index.html
new file mode 100644
index 00000000..6b57150e
--- /dev/null
+++ b/versions/new-website/docs/api/yarn/index.html
@@ -0,0 +1,26 @@
+
+Hilbish
Yarn is a simple multithreading library. Threads are individual Lua states,
+so they do NOT share the same environment as the code that runs the thread.
+Bait and Commanders are shared though, so you can throw hooks from 1 thread to another.
Example:
local yarn = require 'yarn'
+
+-- calling t will run the yarn thread.
+local t = yarn.thread(print)
+t 'printing from another lua state!'
+
Creates a new, fresh Yarn thread.
+fun is the function that will run in the thread.
Parameters
This function has no parameters.
Types
Thread
Methods
\ No newline at end of file
diff --git a/versions/new-website/docs/completions/index.html b/versions/new-website/docs/completions/index.html
index fd69c329..24fe71f7 100644
--- a/versions/new-website/docs/completions/index.html
+++ b/versions/new-website/docs/completions/index.html
@@ -1,5 +1,5 @@
-Hilbish
Completions for commands can be created with the hilbish.complete
function. See the link for how to use it.
To create completions for a command is simple.
The callback will be passed 3 parameters:
- query (string): The text that the user is currently trying to complete.
@@ -30,7 +30,7 @@ local cg2 = {
type = 'grid'
}
return {cg, cg2}, prefix
Which looks like this:
-{{< video src="https://safe.saya.moe/t4CiLK6dgPbD.mp4" >}}
Completion Group Types
grid
+{{< video src="https://safe.saya.moe/t4CiLK6dgPbD.mp4" >}}
Completion Group Types
grid
Grid is the simplest completion group type. All items are strings and when
completion is done is displayed in a grid based on size.
Example:
lua
@@ -38,7 +38,7 @@ completion is done is displayed in a grid based on size.
Example:
items = {'just', 'a bunch', 'of items', 'here', 'hehe'},
type = 'grid'
}
-
list
+
list
The list completion group type displays in a list. A list item can either be a string, or a table for additional display options.
A completion alias can be specified either as the 2nd entry in the options table
or te alias key.
A description can optionally be displayed for a list item, which is either the 1st
@@ -61,7 +61,7 @@ overrides what the completion item looks like.
Example:
},
type = 'list'
}
-
Completion Handler
+
Completion Handler
Like most parts of Hilbish, it's made to be extensible and
customizable. The default handler for completions in general can
be overwritten to provide more advanced completions if needed.
@@ -76,4 +76,4 @@ for the command or fallback to file completions.
To overwrite it, just as
function hilbish.completion.handler(line, pos)
-- do things
end
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/versions/new-website/docs/faq/index.html b/versions/new-website/docs/faq/index.html
index c28ae4e2..fc7e726c 100644
--- a/versions/new-website/docs/faq/index.html
+++ b/versions/new-website/docs/faq/index.html
@@ -1,14 +1,14 @@
-Hilbish
Is Hilbish POSIX compliant?
No, it is not. POSIX compliance is a non-goal. Perhaps in the future,
someone would be able to write a native plugin to support shell scripting
-(which would be against it's main goal, but ....)
Windows Support?
+(which would be against it's main goal, but ....)
Windows Support?
It compiles for Windows (CI ensures it does), but otherwise it is not
directly supported. If you'd like to improve this situation,
-checkout the discussion.
Why?
Hilbish emerged from the desire of a Lua configured shell.
It was the initial reason that it was created, but now it's more:
-to be hyper extensible, simpler and more user friendly.
Does it have "autocompletion" or "tab completion"
+to be hyper extensible, simpler and more user friendly.
Does it have "autocompletion" or "tab completion"
Of course! This is a modern shell. Hilbish provides a way for users
to write tab completion for any command and/or the whole shell.
-Inline hinting and syntax highlighting are also available.
\ No newline at end of file
+Inline hinting and syntax highlighting are also available.
\ No newline at end of file
diff --git a/versions/new-website/docs/features/index.html b/versions/new-website/docs/features/index.html
index 4710a03d..fa5950cf 100644
--- a/versions/new-website/docs/features/index.html
+++ b/versions/new-website/docs/features/index.html
@@ -1,5 +1,5 @@
-Hilbish
Hilbish has a wide range of features to enhance the user's experience
new ones are always being added. If there is something missing here or
something you would like to see, please start a discussion
-or comment on any existing ones which match your request.
\ No newline at end of file
+or comment on any existing ones which match your request.
\ No newline at end of file
diff --git a/versions/new-website/docs/features/notifications/index.html b/versions/new-website/docs/features/notifications/index.html
index cc9a8bbc..2b861d55 100644
--- a/versions/new-website/docs/features/notifications/index.html
+++ b/versions/new-website/docs/features/notifications/index.html
@@ -1,5 +1,5 @@
-Hilbish
Hilbish features a simple notification system which can be
used by other plugins and parts of the shell to notify the user
of various actions. This is used via the hilbish.message interface.
A message is defined as a table with the following properties:
- icon: A unicode/emoji icon for the notification.
@@ -20,4 +20,4 @@ the message will not be stored by the message handler.
It could also be used as some "inter-shell" messaging system (???) but
is intended to display to users.
An example is notifying users of completed jobs/commands ran in the background.
Any Hilbish-native command (think the upcoming Greenhouse pager) can display
-it.
\ No newline at end of file
+it.
\ No newline at end of file
diff --git a/versions/new-website/docs/features/opts/index.html b/versions/new-website/docs/features/opts/index.html
index 1c36a653..7edc262d 100644
--- a/versions/new-website/docs/features/opts/index.html
+++ b/versions/new-website/docs/features/opts/index.html
@@ -1,9 +1,9 @@
-Hilbish
Opts are simple toggle or value options a user can set in Hilbish.
As toggles, there are things like autocd or history saving. As values,
there is the motd which the user can either change to a custom string or disable.
Opts are accessed from the hilbish.opts table. Here they can either
-be read or modified
autocd
Value: boolean
-Default: false
The autocd opt makes it so that lone directories attempted to be executed are
+be read or modified
autocd
Value: boolean
+Default: false
The autocd opt makes it so that lone directories attempted to be executed are
instead set as the shell's directory.
Example:
~/Directory
@@ -14,24 +14,24 @@ instead set as the shell's directory.
Example:
∆ ../Documents
~/Documents
∆
-
<hr>
history
Value: boolean
+
<hr>
history
Value: boolean
Default: true
-Sets whether command history will be saved or not.
<hr>
+Sets whether command history will be saved or not.
<hr>
### greeting
#### Value: boolean or string
The greeting is the message that Hilbish shows on startup
-(the one which says Welcome to Hilbish).
This can be set to either true/false to enable/disable or a custom greeting string.
<hr>
motd
Value: boolean
+(the one which says Welcome to Hilbish).
This can be set to either true/false to enable/disable or a custom greeting string.
<hr>
motd
Value: boolean
Default: true
The message of the day shows the current major.minor version and
-includes a small range of things added in the current release.
This can be set to false to disable the message.
<hr>
fuzzy
Value: boolean
+includes a small range of things added in the current release.
This can be set to false to disable the message.
<hr>
fuzzy
Value: boolean
Default: false
Toggles the functionality of fuzzy history searching, usable
via the menu in Ctrl-R. Fuzzy searching is an approximate searching
method, which means results that match closest will be shown instead
-of an exact match.
<hr>
notifyJobFinish
Value: boolean
+of an exact match.
<hr>
notifyJobFinish
Value: boolean
Default: true
If this is enabled, when a background job is finished,
-a notification will be sent.
Value: table
Default: {}
-A table listing the names of command processors to skip.
\ No newline at end of file
+A table listing the names of command processors to skip.
\ No newline at end of file
diff --git a/versions/new-website/docs/features/runner-mode/index.html b/versions/new-website/docs/features/runner-mode/index.html
index 024869ec..28886459 100644
--- a/versions/new-website/docs/features/runner-mode/index.html
+++ b/versions/new-website/docs/features/runner-mode/index.html
@@ -1,5 +1,5 @@
-Hilbish
Hilbish allows you to change how interactive text can be interpreted.
This is mainly due to the fact that the default method Hilbish uses
is that it runs Lua first and then falls back to shell script.
In some cases, someone might want to switch to just shell script to avoid
it while interactive but still have a Lua config, or go full Lua to use
@@ -13,7 +13,7 @@ first then going to shell script. If you want the reverse order, you can
set it to hybridRev and for isolated modes there is sh and lua
respectively.
You can also set it to a function, which will be called everytime Hilbish
needs to run interactive input. For more detail, see the API documentation
The hilbish.runner interface is an alternative to using hilbish.runnerMode
-and also provides the shell script and Lua runner functions that Hilbish itself uses.
Functions
+and also provides the shell script and Lua runner functions that Hilbish itself uses.
Functions
These are the "low level" functions for the hilbish.runner interface.
+ setMode(mode) > The same as hilbish.runnerMode
+ sh(input) -> table > Runs input in Hilbish's sh interpreter
+ lua(input) -> table > Evals input as Lua code
These functions should be preferred over the previous ones.
@@ -26,4 +26,4 @@ overwrites if the name
+ get(name) > runner > Gets a runner by name. It is a table with at least a
run function, to run input.
+ exec(cmd, runnerName) > Runs cmd with a runner. If runnerName isn't passed,
-the current runner mode is used.
\ No newline at end of file
+the current runner mode is used.
\ No newline at end of file
diff --git a/versions/new-website/docs/getting-started/index.html b/versions/new-website/docs/getting-started/index.html
index ce0d481c..a9f4b825 100644
--- a/versions/new-website/docs/getting-started/index.html
+++ b/versions/new-website/docs/getting-started/index.html
@@ -1,20 +1,20 @@
-Hilbish
To start Hilbish, open a terminal. If Hilbish has been installed and is not the
default shell, you can simply run hilbish to start it. This will launch
a normal interactive session.
-To exit, you can either run the exit command or hit Ctrl+D.
Setting as Default
Login shell
+To exit, you can either run the exit command or hit Ctrl+D.
Setting as Default
Login shell
There are a few ways to make Hilbish your default shell. A simple way is
to make it your user/login shell.
{{< warning It is not recommended to set Hilbish as your login shell. That
is expected to be a POSIX compliant shell, which Hilbish is not. Though if
you still decide to do it, there will just be a few variables missing in
your environment >}}
To do that, simply run chsh -s /usr/bin/hilbish.
Some distros (namely Fedora) might have lchsh instead, which is used like lchsh <user>.
-When prompted, you can put the path for Hilbish.
Default with terminal
+When prompted, you can put the path for Hilbish.
Default with terminal
The simpler way is to set the default shell for your terminal. The way of
-doing this depends on how your terminal settings are configured.
Run after login shell
+doing this depends on how your terminal settings are configured.
Run after login shell
Some shells (like zsh) have an rc file, like .zlogin, which is ran when the shell session
is a login shell. In that file, you can run Hilbish. Example:
exec hilbish -S -l
-
This will replace the shell with Hilbish, set $SHELL to Hilbish and launch it as a login shell.
Configuration
+
This will replace the shell with Hilbish, set $SHELL to Hilbish and launch it as a login shell.
Configuration
Once installation and setup has been done, you can then configure Hilbish.
It is configured and scripted via Lua, so the config file is a Lua file.
You can use any pure Lua library to do whatever you want.
Hilbish's sample configuration is usually located in hilbish.dataDir .. '/.hilbishrc.lua'.
@@ -38,4 +38,4 @@ to change our prompt. Change our prompt to what, exactly?
The doc for the
of the shell, respectively.
We wrap this in the lunacolors.format function, to give
our prompt some nice color.
But you might have also noticed that this is in the doPrompt function, which is called once,
and then used again in a bait hook. Specifically, the command.exit hook,
-which is called after a command exits, so when it finishes running.
\ No newline at end of file
+which is called after a command exits, so when it finishes running.
\ No newline at end of file
diff --git a/versions/new-website/docs/hooks/command/index.html b/versions/new-website/docs/hooks/command/index.html
index 1863f222..0bab3c8a 100644
--- a/versions/new-website/docs/hooks/command/index.html
+++ b/versions/new-website/docs/hooks/command/index.html
@@ -1,14 +1,14 @@
-Hilbish
command.preexec
+Thrown right before a command is executed.
Variables
string **input**
The raw string that the user typed. This will include the text
without changes applied to it (argument substitution, alias expansion,
-etc.)
string **cmdStr**
-The command that will be directly executed by the current runner.
<hr>
command.exit
-Thrown after the user's ran command is finished.
Variables
+etc.)
string **cmdStr**
+The command that will be directly executed by the current runner.
<hr>
command.exit
+Thrown after the user's ran command is finished.
Variables
number **code**
-The exit code of what was executed.
string **cmdStr**
+The exit code of what was executed.
string **cmdStr**
The command or code that was executed
<hr>
## command.not-found
@@ -24,12 +24,12 @@ end
-- then assign custom
bait.catch('command.not-found', function(cmd)
print(string.format('The command "%s" was not found.', cmd))
end)
-
Variables
+
Variables
string **cmdStr**
-The name of the command.
<hr>
+The name of the command.
<hr>
## command.not-executable
Thrown when the user attempts to run a file that is not executable
-(like a text file, or Unix binary without +x permission).
Variables
+(like a text file, or Unix binary without +x permission).
Variables
string **cmdStr**
-The name of the command.
\ No newline at end of file
+The name of the command.
\ No newline at end of file
diff --git a/versions/new-website/docs/hooks/hilbish/index.html b/versions/new-website/docs/hooks/hilbish/index.html
index 5526a646..433b5443 100644
--- a/versions/new-website/docs/hooks/hilbish/index.html
+++ b/versions/new-website/docs/hooks/hilbish/index.html
@@ -1,25 +1,25 @@
-Hilbish
hilbish.vimMode
Sent when the Vim mode of Hilbish is changed (like from insert to normal mode).
-This can be used to change the prompt and notify based on Vim mode.
Variables
+This can be used to change the prompt and notify based on Vim mode.
Variables
string **modeName**
The mode that has been set.
-Can be these values: insert, normal, delete or replace
<hr>
hilbish.cancel
-Sent when the user cancels their command input with Ctrl-C
Variables
-This signal returns no variables.
<hr>
hilbish.notification
-Thrown when a notification is sent.
Variables
+Can be these values: insert, normal, delete or replace
<hr>
hilbish.cancel
+Sent when the user cancels their command input with Ctrl-C
Variables
+This signal returns no variables.
<hr>
hilbish.notification
+Thrown when a notification is sent.
Variables
table **notification**
-The notification. The properties are defined in the link above.
<hr>
hilbish.cd
+The notification. The properties are defined in the link above.
<hr>
hilbish.cd
Sent when the current directory of the shell is changed (via interactive means.)
If you are implementing a custom command that changes the directory of the shell,
-you must throw this hook manually for correctness.
Variables
+you must throw this hook manually for correctness.
Variables
string **path**
-Absolute path of the directory that was changed to.
string **oldPath**
-Absolute path of the directory Hilbish was in.
<hr>
hilbish.vimAction
+Absolute path of the directory that was changed to.
string **oldPath**
+Absolute path of the directory Hilbish was in.
<hr>
hilbish.vimAction
Sent when the user does a "vim action," being something like yanking or pasting text.
-See doc vim-mode actions for more info.
Variables
+See doc vim-mode actions for more info.
Variables
string **actionName**
-Absolute path of the directory that was changed to.
table **args**
-Table of args relating to the Vim action.
<hr>
\ No newline at end of file
+Absolute path of the directory that was changed to.
table **args**
+Table of args relating to the Vim action.
<hr>
\ No newline at end of file
diff --git a/versions/new-website/docs/hooks/index.html b/versions/new-website/docs/hooks/index.html
index 91bd3ec6..a326997d 100644
--- a/versions/new-website/docs/hooks/index.html
+++ b/versions/new-website/docs/hooks/index.html
@@ -1,3 +1,3 @@
-Hilbish
Signals are global events emitted with the Bait module.
+For more detail on how to use these signals, you may check the Bait page.
\ No newline at end of file
diff --git a/versions/new-website/docs/hooks/job/index.html b/versions/new-website/docs/hooks/job/index.html
index 30b945c9..396b0763 100644
--- a/versions/new-website/docs/hooks/job/index.html
+++ b/versions/new-website/docs/hooks/job/index.html
@@ -1,3 +1,3 @@
-Hilbish
Note: job refers to a job object. You can check doc jobs for more
+detail.
+ job.start -> job > Thrown when a new background job starts.
+ job.done -> job > Thrown when a background jobs exits.
\ No newline at end of file
diff --git a/versions/new-website/docs/hooks/signal/index.html b/versions/new-website/docs/hooks/signal/index.html
index 3077a216..7cec2b0c 100644
--- a/versions/new-website/docs/hooks/signal/index.html
+++ b/versions/new-website/docs/hooks/signal/index.html
@@ -1,13 +1,13 @@
-Hilbish
signal.sigint
Thrown when Hilbish receive the SIGINT signal,
-aka when Ctrl-C is pressed.
Variables
-This signal returns no variables.
<hr>
+aka when Ctrl-C is pressed.
Variables
+This signal returns no variables.
<hr>
## signal.resize
-Thrown when the terminal is resized.
Variables
-This signal returns no variables.
<hr>
signal.sigusr1
-Thrown when SIGUSR1 is sent to Hilbish.
Variables
-This signal returns no variables.
<hr>
signal.sigusr2
-Thrown when SIGUSR2 is sent to Hilbish.
Variables
-This signal returns no variables.
\ No newline at end of file
+Thrown when the terminal is resized.
Variables
+This signal returns no variables.
<hr>
signal.sigusr1
+Thrown when SIGUSR1 is sent to Hilbish.
Variables
+This signal returns no variables.
<hr>
signal.sigusr2
+Thrown when SIGUSR2 is sent to Hilbish.
Variables
+This signal returns no variables.
\ No newline at end of file
diff --git a/versions/new-website/docs/index.html b/versions/new-website/docs/index.html
index 5adf6374..4bedd55c 100644
--- a/versions/new-website/docs/index.html
+++ b/versions/new-website/docs/index.html
@@ -1,5 +1,5 @@
-Hilbish
Hilbish is a hyper-extensible shell mainly intended for interactive use.
To enhance the interactive experience, Hilbish comes with a wide range
of features and sane defaults, including a nice looking prompt,
-advanced completion menus and history search.
Here documents some of the features of Hilbish and the Lua API.
\ No newline at end of file
+advanced completion menus and history search.
Here documents some of the features of Hilbish and the Lua API.
\ No newline at end of file
diff --git a/versions/new-website/docs/jobs/index.html b/versions/new-website/docs/jobs/index.html
index e3d81fcc..c18a844c 100644
--- a/versions/new-website/docs/jobs/index.html
+++ b/versions/new-website/docs/jobs/index.html
@@ -1,20 +1,20 @@
-Hilbish
Hilbish has pretty standard job control. It's missing one or two things,
but works well. One thing which is different from other shells
(besides Hilbish) itself is the API for jobs, and of course it's in Lua.
-You can add jobs, stop and delete (disown) them and even get output.
Job Interface
-The job interface refers to hilbish.jobs.
Functions
+You can add jobs, stop and delete (disown) them and even get output.
Job Interface
+The job interface refers to hilbish.jobs.
Functions
(Note that in the list here, they're called from hilbish.jobs, so
a listing of foo would mean hilbish.jobs.foo)
all() -> {jobs}: Returns a table of all jobs.
last() -> job: Returns the last added job.
get(id) -> job: Get a job by its ID.
add(cmdstr, args, execPath) -> job: Adds a new job to the job table.
Note that this does not run the command; You have to start it manually.
cmdstr is the user's input for the job, args is a table of arguments
for the command. It includes arg0 (don't set it as entry 0 in the table)
and execPath is an absolute path for the command executable.
-- disown(id): Removes a job by ID from the job table.
Job Object
+- disown(id): Removes a job by ID from the job table.
Job Object
A job object is a piece of userdata. All the functions of a job require
you to call them with a colon, since they are methods for the job object.
Example: hilbish.jobs.last():foreground()
Which will foreground the last job.
You can still have a job object for a disowned job,
-it just won't be working anywhere. :^)
Properties
+it just won't be working anywhere. :^)
Properties
- cmd: command string
- running: boolean whether the job is running
- id: unique id for the job
@@ -22,9 +22,9 @@ it just won't be working anywhere. :^)
exitCode: exit code of the job
In ordinary cases you'd prefer to use the id instead of pid.
The id is unique to Hilbish and is how you get jobs with the
-hilbish.jobs interface. It may also not describe the job entirely.
Functions
+hilbish.jobs interface. It may also not describe the job entirely.
Functions
- stop(): Stops the job.
- start(): Starts the job.
- foreground(): Set the job as the current running foreground process, or
run it in the foreground after it has been suspended.
-- background(): Run the job in the background after it has been suspended.
\ No newline at end of file
+- background(): Run the job in the background after it has been suspended.
\ No newline at end of file
diff --git a/versions/new-website/docs/lunacolors/index.html b/versions/new-website/docs/lunacolors/index.html
index cbe0ee18..ff8f38ef 100644
--- a/versions/new-website/docs/lunacolors/index.html
+++ b/versions/new-website/docs/lunacolors/index.html
@@ -1,5 +1,5 @@
-Hilbish
Lunacolors is an ANSI color/styling library for Lua. It is included
by default in standard Hilbish distributions to provide easy styling
for things like prompts and text.
For simple usage, a single color or style is enough. For example,
you can just use lunacolors.blue 'Hello world' and that'll return
@@ -27,4 +27,4 @@ Styles:
variants have a Bg suffix, while bright variants use the bright prefix.
These can also be combined. Note that appropriate camel casing must be applied.
For example, bright blue would be written as brightBlue, a cyan background as
-cyanBg, and combining them would result in brightBlueBg.
\ No newline at end of file
+cyanBg, and combining them would result in brightBlueBg.
\ No newline at end of file
diff --git a/versions/new-website/docs/nature/dirs/index.html b/versions/new-website/docs/nature/dirs/index.html
index 7ed57a95..2295c665 100644
--- a/versions/new-website/docs/nature/dirs/index.html
+++ b/versions/new-website/docs/nature/dirs/index.html
@@ -1,7 +1,7 @@
-Hilbish
Introduction
The dirs module defines a small set of functions to store and manage
-directories.
Functions
+directories.
Functions
|||
|----|----|
|<a href="#setOld">setOld(d)</a>|Sets the old directory string.|
@@ -55,4 +55,4 @@ dirs.setOld(d)
</a>
</h4>
Sets the old directory string.
#### Parameters
-d **string**
</div>
\ No newline at end of file
+d **string**
</div>
\ No newline at end of file
diff --git a/versions/new-website/docs/nature/doc/index.html b/versions/new-website/docs/nature/doc/index.html
index 20517e94..9393c8f3 100644
--- a/versions/new-website/docs/nature/doc/index.html
+++ b/versions/new-website/docs/nature/doc/index.html
@@ -1,9 +1,9 @@
-Hilbish
Introduction
The doc module contains a small set of functions
used by the Greenhouse pager to render parts of the documentation pages.
This is only documented for the sake of it. It's only intended use
-is by the Greenhouse pager.
Functions
+is by the Greenhouse pager.
Functions
|||
|----|----|
|<a href="#renderInfoBlock">renderInfoBlock(type, text)</a>|Renders an info block. An info block is a block of text with|
@@ -41,4 +41,4 @@ doc.renderInfoBlock(type, text)
an icon and styled text block.
#### Parameters
type **string**
-Type of info block. The only one specially styled is the warning.
text **string**
</div>
\ No newline at end of file
+Type of info block. The only one specially styled is the warning.
text **string**
</div>
\ No newline at end of file
diff --git a/versions/new-website/docs/nature/index.html b/versions/new-website/docs/nature/index.html
index 78308159..66b23b25 100644
--- a/versions/new-website/docs/nature/index.html
+++ b/versions/new-website/docs/nature/index.html
@@ -1,9 +1,9 @@
-Hilbish
A bit after creation, we have the outside nature. Little plants, seeds,
growing to their final phase: a full plant. A lot of Hilbish itself is
written in Go, but there are parts made in Lua, being most builtins
(doc, cd, cdr), completions, and other things.
Hilbish's Lua core module is called nature.
-It runs after Hilbish's Go core does.
Nature Modules
+It runs after Hilbish's Go core does.
Nature Modules
Currently, nature provides 1 intended public module: nature.dirs.
It is a simple API for managing recent directories and old
-current working directory.
\ No newline at end of file
+current working directory.
\ No newline at end of file
diff --git a/versions/new-website/docs/timers/index.html b/versions/new-website/docs/timers/index.html
index 318680fc..9a2a1ae2 100644
--- a/versions/new-website/docs/timers/index.html
+++ b/versions/new-website/docs/timers/index.html
@@ -1,2 +1,2 @@
-Hilbish
This has been moved to the hilbish.timers API doc (accessible by doc api hilbish.timers)
\ No newline at end of file
diff --git a/versions/new-website/docs/vim-mode/actions/index.html b/versions/new-website/docs/vim-mode/actions/index.html
index c37c3f1e..ebd0c35b 100644
--- a/versions/new-website/docs/vim-mode/actions/index.html
+++ b/versions/new-website/docs/vim-mode/actions/index.html
@@ -1,7 +1,7 @@
-Hilbish
Vim actions are essentially just when a user uses a Vim keybind.
Things like yanking and pasting are Vim actions.
This is not an "offical Vim thing," just a Hilbish thing.
The hilbish.vimAction hook is thrown whenever a Vim action occurs.
It passes 2 arguments: the action name, and an array (table) of args
relating to it.
Here is documentation for what the table of args will hold for an
-appropriate Vim action.
yank: register, yankedText
The first argument for the yank action is the register yankedText goes to.
paste: register, pastedText
The first argument for the paste action is the register pastedText is taken from.
\ No newline at end of file
+appropriate Vim action.
yank: register, yankedText
The first argument for the yank action is the register yankedText goes to.
paste: register, pastedText
The first argument for the paste action is the register pastedText is taken from.
\ No newline at end of file
diff --git a/versions/new-website/docs/vim-mode/index.html b/versions/new-website/docs/vim-mode/index.html
index 933bedb1..b9792fd0 100644
--- a/versions/new-website/docs/vim-mode/index.html
+++ b/versions/new-website/docs/vim-mode/index.html
@@ -1,3 +1,3 @@
-Hilbish
Hilbish has a Vim binding input mode accessible for use.
+It can be enabled with the hilbish.inputMode function (check doc hilbish).
This is documentation for everything relating to it.
\ No newline at end of file
diff --git a/versions/new-website/index.html b/versions/new-website/index.html
index bc31dcd6..584071d0 100644
--- a/versions/new-website/index.html
+++ b/versions/new-website/index.html
@@ -1,8 +1,8 @@
-Hilbish
Hilbish
Something Unique.
Hilbish is the new Moon-powered interactive shell for Lua fans! Extensible, scriptable, configurable: All in Lua.
Scroll for more
Feature Overview
The Moon-powered shell
Hilbish makes use of the Lua programming language for interactive and config scripting.
+
Hilbish
Hilbish
Something Unique.
Hilbish is the new Moon-powered interactive shell for Lua fans! Extensible, scriptable, configurable: All in Lua.
Scroll for more
Feature Overview
What Makes Hilbish Great?
The Moon-powered shell
Hilbish makes use of the Lua programming language for interactive and config scripting.
If you write Lua on a regular basis, Hilbish will be the perfect resident in your terminal.
- You can still use shell script, but Lua takes the spotlight (or the moonlight..)
Modern, Helpful Interactive Features
Graphical TUI history, sensible tab completions, elegantly refreshing prompts, name it all and Hilbish either has it or it's 1 suggestion or 1 script away from being possible.
- Everything present in Hilbish is meant to enhance your interactive shell experience.
Sensible, Friendly Defaults
Hilbish's default config makes a simple but presentable showcase of its Lua API and a few of its features.
Truly Make It Yours
Many things about Hilbish are designed to be changed and swapped out.
+ You can still use shell script, but Lua takes the spotlight (or the moonlight..)
Modern, Helpful Interactive Features
Graphical TUI history, sensible tab completions, elegantly refreshing prompts, name it all and Hilbish either has it or it's 1 suggestion or 1 script away from being possible.
+ Everything present in Hilbish is meant to enhance your interactive shell experience.
Sensible, Friendly Defaults
Hilbish's default config makes a simple but presentable showcase of its Lua API and a few of its features.
Truly Make It Yours
Many things about Hilbish are designed to be changed and swapped out.
If you want to make use of a Lua derivative in your interactive use (like Fennel) instead of
- Lua, that can be done!
Download It Now!
To find out all that Hilbish can do, you should just try it out! It's officially available on Linux, MacOS, Windows, and probably builds on anything Go is available on!
Featured Downloads
These are binary releases of Hilbish from GitHub. Install instructions are located at an INSTALL.md file.
\ No newline at end of file
+ Lua, that can be done!
Download It Now!
To find out all that Hilbish can do, you should just try it out! It's officially available on Linux, MacOS, Windows, and probably builds on anything Go is available on!
Featured Downloads
These are binary releases of Hilbish from GitHub. Install instructions are located at an INSTALL.md file.
\ No newline at end of file
diff --git a/versions/new-website/install/index.html b/versions/new-website/install/index.html
index b164795b..5d3b751c 100644
--- a/versions/new-website/install/index.html
+++ b/versions/new-website/install/index.html
@@ -1,6 +1,6 @@
-Hilbish