Compare commits
No commits in common. "32a924fa4eeb70f2472b05e9209161fcf5871894" and "5b0cdc5b21ab5db4f9af6f8e6d39a65c1e497469" have entirely different histories.
32a924fa4e
...
5b0cdc5b21
7
LICENSE
7
LICENSE
|
@ -1,7 +0,0 @@
|
|||
"THE BEER-WARE LICENSE" (Revision 42):
|
||||
|
||||
<jonjmaa@gmail.com> wrote this program. As long as you retain this notice you
|
||||
can do whatever you want with this stuff. If we meet some day, and you think
|
||||
this stuff is worth it, you can buy me a beer in return.
|
||||
|
||||
Jon Michael Aanes
|
6
LICENSE.txt
Normal file
6
LICENSE.txt
Normal file
|
@ -0,0 +1,6 @@
|
|||
|
||||
<jonjmaa@gmail.com> wrote this library. As long as you retain this notice you
|
||||
can do whatever you want with this stuff. If we meet some day, and you think
|
||||
this stuff is worth it, you can buy me a beer in return.
|
||||
- Jon Michael Aanes
|
||||
|
20
README.md
20
README.md
|
@ -1,19 +1,3 @@
|
|||
<!--- WARNING --->
|
||||
<!--- THIS IS AN AUTO-GENERATED FILE --->
|
||||
<!--- MANUAL CHANGES CAN AND WILL BE OVERWRITTEN --->
|
||||
# Errors
|
||||
|
||||
# Lua library for advanced error handling.
|
||||
|
||||
|
||||
|
||||
# License
|
||||
|
||||
```
|
||||
"THE BEER-WARE LICENSE" (Revision 42):
|
||||
|
||||
<jonjmaa@gmail.com> wrote this program. As long as you retain this notice you
|
||||
can do whatever you want with this stuff. If we meet some day, and you think
|
||||
this stuff is worth it, you can buy me a beer in return.
|
||||
|
||||
Jon Michael Aanes
|
||||
```
|
||||
Lua Library for advanced error handling.
|
||||
|
|
11
errors.lua
11
errors.lua
|
@ -1,15 +1,14 @@
|
|||
--- # Errors
|
||||
--
|
||||
-- Lua library for advanced error handling.
|
||||
|
||||
-- Check for possible loading errors
|
||||
|
||||
local string_dist
|
||||
do
|
||||
local this_path = ... and (...):match('.+%.') or ''
|
||||
local thispath = ... and (...):match('.+%.') or ''
|
||||
local function import (name, ignore_failure)
|
||||
local was_loaded, lib_or_error = pcall(require, this_path..name)
|
||||
local was_loaded, lib_or_error = pcall(require, thispath..name)
|
||||
if not was_loaded then
|
||||
if ignore_failure then return nil end
|
||||
error('['..this_path..']: Could not load vital library: '..name..'.lua:\n\t'..lib_or_error)
|
||||
error('['..thispath..']: Could not load vital library: '..name..'.lua:\n\t'..lib_or_error)
|
||||
end
|
||||
return lib_or_error
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user