summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/luv/examples/uvbook/onchange.lua
diff options
context:
space:
mode:
author ImJezze <jezze@gmx.net>2016-03-12 12:31:13 +0100
committer ImJezze <jezze@gmx.net>2016-03-12 12:31:13 +0100
commita026a582f1a0ea8c1ede3acaddacef506ef3f3b0 (patch)
treee31573822f2359677de519f9f3b600d98e8764cd /3rdparty/luv/examples/uvbook/onchange.lua
parent477d2abd43984f076b7e45f5527591fa8fd0d241 (diff)
parentdcab55bf53b94713a6f72e9633f5101c8dd6c08c (diff)
Merge pull request #15 from mamedev/master
Sync to base master
Diffstat (limited to '3rdparty/luv/examples/uvbook/onchange.lua')
-rw-r--r--3rdparty/luv/examples/uvbook/onchange.lua30
1 files changed, 0 insertions, 30 deletions
diff --git a/3rdparty/luv/examples/uvbook/onchange.lua b/3rdparty/luv/examples/uvbook/onchange.lua
deleted file mode 100644
index 07b3f9b1d78..00000000000
--- a/3rdparty/luv/examples/uvbook/onchange.lua
+++ /dev/null
@@ -1,30 +0,0 @@
-local uv = require('luv')
-
-if #arg==0 then
- print(string.format("Usage: %s <command> <file1> [file2 ...]",arg[0]));
- return
-end
-
-for i=1,#arg do
- local fse = uv.new_fs_event()
- assert(uv.fs_event_start(fse,arg[i],{
- --"watch_entry"=true,"stat"=true,
- recursive=true
- },function (err,fname,status)
- if(err) then
- print("Error "..err)
- else
- print(string.format('Change detected in %s',
- uv.fs_event_getpath(fse)))
- for k,v in pairs(status) do
- print(k,v)
- end
- print('file changed:'..(fname and fname or ''))
- end
- end))
-
-end
-
-uv.run('default')
-uv.loop_close()
-