mirror of https://github.com/Hilbis/Hilbish
Compare commits
3 Commits
cc6e5d01dd
...
6ffcc498ac
Author | SHA1 | Date |
---|---|---|
TorchedSammy | 6ffcc498ac | |
TorchedSammy | fe47c6c7a1 | |
sammy | 0d32a10ca3 |
|
@ -75,6 +75,7 @@ disables commands being added to history.
|
||||||
- A new and "safer" event emitter has been added. This causes a performance deficit, but avoids a lot of
|
- A new and "safer" event emitter has been added. This causes a performance deficit, but avoids a lot of
|
||||||
random errors introduced with the new Lua runtime (see [#197])
|
random errors introduced with the new Lua runtime (see [#197])
|
||||||
- `bait.release(name, catcher)` removes `handler` for the named `event`
|
- `bait.release(name, catcher)` removes `handler` for the named `event`
|
||||||
|
- `exec`, `clear` and `cat` builtin commands
|
||||||
|
|
||||||
[#197]: https://github.com/Rosettea/Hilbish/issues/197
|
[#197]: https://github.com/Rosettea/Hilbish/issues/197
|
||||||
|
|
||||||
|
@ -151,6 +152,11 @@ an error of missing format variable
|
||||||
- Prompt now works with east asian characters (CJK)
|
- Prompt now works with east asian characters (CJK)
|
||||||
- Set back the prompt to normal after exiting the continue prompt with ctrl-d
|
- Set back the prompt to normal after exiting the continue prompt with ctrl-d
|
||||||
|
|
||||||
|
## [2.0.0-rc1] - 2022-09-14
|
||||||
|
This is a pre-release version of Hilbish for testing. To see the changelog,
|
||||||
|
refer to the `Unreleased` section of the [full changelog](CHANGELOG.md)
|
||||||
|
(version 2.0.0 for future reference).
|
||||||
|
|
||||||
## [1.2.0] - 2022-03-17
|
## [1.2.0] - 2022-03-17
|
||||||
### Added
|
### Added
|
||||||
- Job Management additions
|
- Job Management additions
|
||||||
|
@ -574,6 +580,8 @@ This input for example will prompt for more input to complete:
|
||||||
|
|
||||||
First "stable" release of Hilbish.
|
First "stable" release of Hilbish.
|
||||||
|
|
||||||
|
[2.0.0-rc1]: https://github.com/Rosettea/Hilbish/compare/v1.2.0...v2.0.0-rc1
|
||||||
|
[1.2.0]: https://github.com/Rosettea/Hilbish/compare/v1.1.4...v1.2.0
|
||||||
[1.1.0]: https://github.com/Rosettea/Hilbish/compare/v1.0.4...v1.1.0
|
[1.1.0]: https://github.com/Rosettea/Hilbish/compare/v1.0.4...v1.1.0
|
||||||
[1.0.4]: https://github.com/Rosettea/Hilbish/compare/v1.0.3...v1.0.4
|
[1.0.4]: https://github.com/Rosettea/Hilbish/compare/v1.0.3...v1.0.4
|
||||||
[1.0.3]: https://github.com/Rosettea/Hilbish/compare/v1.0.2...v1.0.3
|
[1.0.3]: https://github.com/Rosettea/Hilbish/compare/v1.0.2...v1.0.3
|
||||||
|
|
|
@ -0,0 +1,25 @@
|
||||||
|
local commander = require 'commander'
|
||||||
|
local fs = require 'fs'
|
||||||
|
|
||||||
|
commander.register('cat', function(args)
|
||||||
|
local exit = 0
|
||||||
|
|
||||||
|
if #args == 0 then
|
||||||
|
print [[
|
||||||
|
usage: cat [file]...]]
|
||||||
|
end
|
||||||
|
|
||||||
|
for _, fName in ipairs(args) do
|
||||||
|
local f = io.open(fName)
|
||||||
|
if f == nil then
|
||||||
|
exit = 1
|
||||||
|
print(string.format('cat: %s: no such file or directory', fName))
|
||||||
|
goto continue
|
||||||
|
end
|
||||||
|
|
||||||
|
io.write(f:read '*a')
|
||||||
|
::continue::
|
||||||
|
end
|
||||||
|
io.flush()
|
||||||
|
return exit
|
||||||
|
end)
|
|
@ -0,0 +1,7 @@
|
||||||
|
local ansikit = require 'ansikit'
|
||||||
|
local commander = require 'commander'
|
||||||
|
|
||||||
|
commander.register('clear', function()
|
||||||
|
ansikit.clear(true)
|
||||||
|
ansikit.cursorTo(0, 0)
|
||||||
|
end)
|
|
@ -0,0 +1,5 @@
|
||||||
|
local commander = require 'commander'
|
||||||
|
|
||||||
|
commander.register('exec', function(args)
|
||||||
|
hilbish.exec(args[1])
|
||||||
|
end)
|
Loading…
Reference in New Issue