<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/20073" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2015-12-26T15:51:26-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/20073</id>

		<entry>
		<author><name><![CDATA[FmX]]></name></author>
		<updated>2015-12-26T15:51:26-04:00</updated>

		<published>2015-12-26T15:51:26-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=104609#p104609</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=104609#p104609"/>
		<title type="html"><![CDATA[learn.tcl modification request]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=104609#p104609"><![CDATA[
Working perfect  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_cool.gif" width="15" height="15" alt="8)" title="Cool"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8470">FmX</a> — Sat Dec 26, 2015 3:51 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SpiKe^^]]></name></author>
		<updated>2015-12-26T15:42:01-04:00</updated>

		<published>2015-12-26T15:42:01-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=104608#p104608</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=104608#p104608"/>
		<title type="html"><![CDATA[tklearn.tcl by tomekk (v.0.8 mod. by SpiKe^^)]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=104608#p104608"><![CDATA[
The problem is that the read command is now triggering on any command matching this mask: !*<br><br>The easiest fix by far is just a setting in the script, that would allow the script operator to list the !commands being used by this script and other scripts in the channel.<br>Then have this scripts read process ignore those triggers and not reply.<br><br>Let's try this and see if it's better...<div class="codebox"><p>Code: </p><pre><code>########################### tklearn.tcl by tomekk  ## v.0.8 mod. by SpiKe^^  ## www.mytclscripts.com   ## undernet #pc-mirc-help ## date:  26Dec2015       ############################ description: store some various information, new information can be added by public command !add and after# you can view this info by typing ! &lt;command_name&gt;  OR  !&lt;command_name&gt; # use: run script, and use !help on the channel, only op can add, replace, delete, rename, append# if you want to allow normal users to add/del/rep etc. you have to change bind from o|o to -|- # Author: tomekk# e-mail:  tomekk/@/oswiecim/./eu/./org# home page: http://tomekk.oswiecim.eu.org/## Version 0.6## This file is Copyrighted under the GNU Public License.# http://www.gnu.org/copyleft/gpl.html # added: some notices# added: !stored command, shows stored commands# fixed: removed !help command, now each command has its own help, just type !&lt;command_name&gt; without arguments# added: now its possible to set on which channels should this script work # if you want to use this script on your chan, type in eggdrop console (via telnet or DCC chat)# .chanset #channel_name +learn# and later .save # available commands: !add, !del, !rep, !app, !ren, ! &lt;cmd_name&gt;  OR  !&lt;command_name&gt;, !stored # dir with stored filesset dirname "learn.db"# set a list of !commands that the read command should ignore and not reply to.# add any other trigger words for other scripts running in the same channel(s).set ignored "add del rep app ren stored" ################################################################################################bind pub o|o !add add_fctbind pub o|o !del del_fctbind pub o|o !rep rep_fctbind pub o|o !app app_fctbind pub o|o !ren ren_fct#bind pub - ! show_fctbind pubm - "% !*" show_fctbind pub - !stored stored_cmds setudef flag learnset ignored [split [string tolower $ignored]] # force this eggdrop conf setting to be disabled #set exclusive-binds 0if {[file exists $dirname] == 0} {    file mkdir $dirname} proc create_db { dbname definfo } {    if {[file exists $dbname] == 0} {        set crtdb [open $dbname a+]        puts $crtdb "$definfo"        close $crtdb    }} proc readdb { rdb } {    global dbout    set fs_open [open $rdb r]    gets $fs_open dbout    close $fs_open} proc add_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return                      }           set txt [split $arg]     set cmd [string tolower [lindex $txt 0]]     set msg [join [lrange $txt 1 end]]     if {$msg != ""} {        if {[file exists $dirname/$cmd] == 0} {            create_db "$dirname/$cmd" "$msg"            putquick "NOTICE $nick :'$cmd' has been added"        } {            putquick "NOTICE $nick :'$cmd' is already defined"        }    } {        putquick "NOTICE $nick :use: !add &lt;cmd_name&gt; &lt;info&gt;"    }} proc show_fct { nick uhost hand chan arg } {    global dbout dirname ignored    if {![channel get $chan learn]} {        return 0    }    set arg [string trim [string trimleft $arg !]]    set txt [split [string tolower $arg]]    set cmd [lindex $txt 0]    if {[lsearch $ignored $cmd] &gt; "-1"} {  return 0  }    if {$cmd != ""} {        foreach files $txt {            if {$files != ""} {                if {[file exists $dirname/$files] == 1} {                    readdb $dirname/$files                    putquick "PRIVMSG $chan :$files: $dbout"                } {                    putquick "NOTICE $chan :'$files' doesn't exist"                }            }        }    } {        putquick "NOTICE $nick :use: ! &lt;cmd_name&gt; ... &lt;cmd_name&gt;"        putquick "NOTICE $nick :OR: !&lt;cmd_name&gt; ... &lt;cmd_name&gt;"    }    return 0} proc del_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set all_files [glob -tails -directory $dirname -nocomplain -type f *]       set txt [string tolower [split $arg]]         set cmd [lindex $txt 0]     if {$cmd != ""} {        if {$cmd == "all_cmds"} {            foreach xfiles $all_files {                file delete $dirname/$xfiles                putquick "NOTICE $nick :all commands have been deleted"            }        }         if {$cmd != "all_cmds"} {            foreach files $txt {                if {$files != ""} {                    if {[file exists $dirname/$files] == 1} {                        file delete $dirname/$files                        putquick "NOTICE $nick :'$cmd' command has been deleted"                    } {                        putquick "NOTICE $nick :'$cmd' doesn't exists"                    }                }            }        }    } {        putquick "NOTICE $nick :use: !del all_cmds or !del &lt;cmd_name&gt; ... &lt;cmd_name&gt;"    }} proc rep_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set txt [split $arg]         set cmd [string tolower [lindex $txt 0]]         set msg [join [lrange $txt 1 end]]     if {$msg != ""} {        if {[file exists $dirname/$cmd] == 1} {            file delete $dirname/$cmd            create_db "$dirname/$cmd" "$msg"            putquick "NOTICE $nick :'$cmd' has been replaced"        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !rep &lt;cmd_name&gt; &lt;new_info&gt;"    }} proc app_fct { nick uhost hand chan arg } {    global dirname dbout     if {![channel get $chan learn]} {        return    }       set txt [split $arg]       set start [lindex $txt 0]     set cmd [string tolower [lindex $txt 1]]     set app_info [join [lrange $txt 2 end]]     if {$app_info != "" } {        if {[file exists $dirname/$cmd] == 1} {                if {$start == "fb"} {                readdb $dirname/$cmd                file delete $dirname/$cmd                create_db "$dirname/$cmd" "$app_info $dbout"                putquick "NOTICE $nick :done"            }             if {$start == "fe"} {                    readdb $dirname/$cmd                file delete $dirname/$cmd                create_db "$dirname/$cmd" "$dbout $app_info"                putquick "NOTICE $nick :done"            }        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !app &lt;fb|fe&gt; &lt;cmd_name&gt; &lt;additional_info&gt; | fb - from the beginning; fe - from the end;"    }} proc ren_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return        }     set txt [string tolower [split $arg]]         set old [lindex $txt 0]         set new [lindex $txt 1]       if {$new != ""} {        if {[file exists $dirname/$old] == 1} {            file rename $dirname/$old $dirname/$new            putquick "NOTICE $nick :'$old' has been renamed to '$new'"        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !ren &lt;old_cmd_name&gt; &lt;new_cmd_name"    }} proc stored_cmds { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set files [glob -tails -directory $dirname -nocomplain -type f *]     if {$files != ""} {        set names [join $files ", "]    } {        set names "none"    }     putquick "NOTICE $nick :stored commands: $names"} putlog "tklearn.tcl by tomekk (v.0.8 mod. by SpiKe^^) loaded"</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7749">SpiKe^^</a> — Sat Dec 26, 2015 3:42 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[FmX]]></name></author>
		<updated>2015-12-26T14:25:05-04:00</updated>

		<published>2015-12-26T14:25:05-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=104607#p104607</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=104607#p104607"/>
		<title type="html"><![CDATA[learn.tcl modification request]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=104607#p104607"><![CDATA[
Its working but when you add or remove words got this:<div class="codebox"><p>Code: </p><pre><code>&lt;&lt;20:23:30&gt;&gt; &lt;FmX&gt; !add test this is test&lt;&lt;20:23:30&gt;&gt; -X6:#globalnews- 'add' doesn't exist&lt;&lt;20:23:30&gt;&gt; -X6:#globalnews- 'test' doesn't exist&lt;&lt;20:23:30&gt;&gt; -X6:#globalnews- 'this' doesn't exist&lt;&lt;20:23:30&gt;&gt; -X6:#globalnews- 'is' doesn't exist&lt;&lt;20:23:30&gt;&gt; -X6:#globalnews- 'test' doesn't exist&lt;&lt;20:23:33&gt;&gt; -X6- 'test' has been added&lt;&lt;20:23:47&gt;&gt; &lt;FmX&gt; !test&lt;&lt;20:23:47&gt;&gt; &lt;X6&gt; test: this is test</code></pre></div><div class="codebox"><p>Code: </p><pre><code>&lt;&lt;20:33:26&gt;&gt; &lt;FmX&gt; !ren test test2&lt;&lt;20:33:26&gt;&gt; -X6:#globalnews- 'ren' doesn't exist&lt;&lt;20:33:26&gt;&gt; &lt;X6&gt; test: this is test&lt;&lt;20:33:26&gt;&gt; -X6:#globalnews- 'test2' doesn't exist&lt;&lt;20:33:26&gt;&gt; -X6- 'test' has been renamed to 'test2'</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8470">FmX</a> — Sat Dec 26, 2015 2:25 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SpiKe^^]]></name></author>
		<updated>2015-12-25T21:55:21-04:00</updated>

		<published>2015-12-25T21:55:21-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=104606#p104606</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=104606#p104606"/>
		<title type="html"><![CDATA[tklearn.tcl by tomekk (v.0.7 mod. by SpiKe^^)]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=104606#p104606"><![CDATA[
Try this and see what we got.<br>Make sure to .restart the bot with the new script (NOT .rehash).<div class="codebox"><p>Code: </p><pre><code>########################### tklearn.tcl by tomekk  ## v.0.7 mod. by SpiKe^^  ## www.mytclscripts.com   ## undernet #pc-mirc-help ## date:  25Dec2015       ############################ description: store some various information, new information can be added by public command !add and after# you can view this info by typing ! &lt;command_name&gt;  OR  !&lt;command_name&gt; # use: run script, and use !help on the channel, only op can add, replace, delete, rename, append# if you want to allow normal users to add/del/rep etc. you have to change bind from o|o to -|- # Author: tomekk# e-mail:  tomekk/@/oswiecim/./eu/./org# home page: http://tomekk.oswiecim.eu.org/## Version 0.6## This file is Copyrighted under the GNU Public License.# http://www.gnu.org/copyleft/gpl.html # added: some notices# added: !stored command, shows stored commands# fixed: removed !help command, now each command has its own help, just type !&lt;command_name&gt; without arguments# added: now its possible to set on which channels should this script work # if you want to use this script on your chan, type in eggdrop console (via telnet or DCC chat)# .chanset #channel_name +learn# and later .save # available commands: !add, !del, !rep, !app, !ren, ! &lt;cmd_name&gt;  OR  !&lt;command_name&gt;, !stored # dir with stored filesset dirname "learn.db" ################################################################################################bind pub o|o !add add_fctbind pub o|o !del del_fctbind pub o|o !rep rep_fctbind pub o|o !app app_fctbind pub o|o !ren ren_fct#bind pub - ! show_fctbind pubm - "% !*" show_fctbind pub - !stored stored_cmds setudef flag learn # force this eggdrop conf setting to be disabled #set exclusive-binds 0if {[file exists $dirname] == 0} {    file mkdir $dirname} proc create_db { dbname definfo } {    if {[file exists $dbname] == 0} {        set crtdb [open $dbname a+]        puts $crtdb "$definfo"        close $crtdb    }} proc readdb { rdb } {    global dbout    set fs_open [open $rdb r]    gets $fs_open dbout    close $fs_open} proc add_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return                      }           set txt [split $arg]     set cmd [string tolower [lindex $txt 0]]     set msg [join [lrange $txt 1 end]]     if {$msg != ""} {        if {[file exists $dirname/$cmd] == 0} {            create_db "$dirname/$cmd" "$msg"            putquick "NOTICE $nick :'$cmd' has been added"        } {            putquick "NOTICE $nick :'$cmd' is already defined"        }    } {        putquick "NOTICE $nick :use: !add &lt;cmd_name&gt; &lt;info&gt;"    }} proc show_fct { nick uhost hand chan arg } {    global dbout dirname    if {![channel get $chan learn]} {        return 0    }    set arg [string trim [string trimleft $arg !]]    set txt [split [string tolower $arg]]    set cmd [lindex $txt 0]    if {$cmd != ""} {        foreach files $txt {            if {$files != ""} {                if {[file exists $dirname/$files] == 1} {                    readdb $dirname/$files                    putquick "PRIVMSG $chan :$files: $dbout"                } {                    putquick "NOTICE $chan :'$files' doesn't exist"                }            }        }    } {        putquick "NOTICE $nick :use: ! &lt;cmd_name&gt; ... &lt;cmd_name&gt;"        putquick "NOTICE $nick :OR: !&lt;cmd_name&gt; ... &lt;cmd_name&gt;"    }    return 0} proc del_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set all_files [glob -tails -directory $dirname -nocomplain -type f *]       set txt [string tolower [split $arg]]         set cmd [lindex $txt 0]     if {$cmd != ""} {        if {$cmd == "all_cmds"} {            foreach xfiles $all_files {                file delete $dirname/$xfiles                putquick "NOTICE $nick :all commands have been deleted"            }        }         if {$cmd != "all_cmds"} {            foreach files $txt {                if {$files != ""} {                    if {[file exists $dirname/$files] == 1} {                        file delete $dirname/$files                        putquick "NOTICE $nick :'$cmd' command has been deleted"                    } {                        putquick "NOTICE $nick :'$cmd' doesn't exists"                    }                }            }        }    } {        putquick "NOTICE $nick :use: !del all_cmds or !del &lt;cmd_name&gt; ... &lt;cmd_name&gt;"    }} proc rep_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set txt [split $arg]         set cmd [string tolower [lindex $txt 0]]         set msg [join [lrange $txt 1 end]]     if {$msg != ""} {        if {[file exists $dirname/$cmd] == 1} {            file delete $dirname/$cmd            create_db "$dirname/$cmd" "$msg"            putquick "NOTICE $nick :'$cmd' has been replaced"        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !rep &lt;cmd_name&gt; &lt;new_info&gt;"    }} proc app_fct { nick uhost hand chan arg } {    global dirname dbout     if {![channel get $chan learn]} {        return    }       set txt [split $arg]       set start [lindex $txt 0]     set cmd [string tolower [lindex $txt 1]]     set app_info [join [lrange $txt 2 end]]     if {$app_info != "" } {        if {[file exists $dirname/$cmd] == 1} {                if {$start == "fb"} {                readdb $dirname/$cmd                file delete $dirname/$cmd                create_db "$dirname/$cmd" "$app_info $dbout"                putquick "NOTICE $nick :done"            }             if {$start == "fe"} {                    readdb $dirname/$cmd                file delete $dirname/$cmd                create_db "$dirname/$cmd" "$dbout $app_info"                putquick "NOTICE $nick :done"            }        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !app &lt;fb|fe&gt; &lt;cmd_name&gt; &lt;additional_info&gt; | fb - from the beginning; fe - from the end;"    }} proc ren_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return        }     set txt [string tolower [split $arg]]         set old [lindex $txt 0]         set new [lindex $txt 1]       if {$new != ""} {        if {[file exists $dirname/$old] == 1} {            file rename $dirname/$old $dirname/$new            putquick "NOTICE $nick :'$old' has been renamed to '$new'"        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !ren &lt;old_cmd_name&gt; &lt;new_cmd_name"    }} proc stored_cmds { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set files [glob -tails -directory $dirname -nocomplain -type f *]     if {$files != ""} {        set names [join $files ", "]    } {        set names "none"    }     putquick "NOTICE $nick :stored commands: $names"} putlog "tklearn.tcl by tomekk (v.0.7 mod. by SpiKe^^) loaded"</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=7749">SpiKe^^</a> — Fri Dec 25, 2015 9:55 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[FmX]]></name></author>
		<updated>2015-12-25T14:40:55-04:00</updated>

		<published>2015-12-25T14:40:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=104605#p104605</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=104605#p104605"/>
		<title type="html"><![CDATA[learn.tcl modification request]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=104605#p104605"><![CDATA[
Hello, how to make this script to show learned words like that !WORD instead of ! WORD without space ? <br>Here is the code: <br><div class="codebox"><p>Code: </p><pre><code># description: store some various information, new information can be added by public command !add and after# you can view this info by typing ? &lt;command_name&gt; # use: run script, and use !help on the channel, only op can add, replace, delete, rename, append# if you want to allow normal users to add/del/rep etc. you have to change bind from o|o to -|- # Author: tomekk# e-mail:  tomekk/@/oswiecim/./eu/./org# home page: http://tomekk.oswiecim.eu.org/## Version 0.6## This file is Copyrighted under the GNU Public License.# http://www.gnu.org/copyleft/gpl.html # added: some notices# added: !stored command, shows stored commands# fixed: removed !help command, now each command has its own help, just type !&lt;command_name&gt; without arguments# added: now its possible to set on which channels should this script work # if you want to use this script on your chan, type in eggdrop console (via telnet or DCC chat)# .chanset #channel_name +learn# and later .save # available commands: !add, !del, !rep, !app, !ren, ? &lt;cmd_name&gt;, !stored # dir with stored filesset dirname "learn.db" ################################################################################################bind pub o|o !add add_fctbind pub o|o !del del_fctbind pub o|o !rep rep_fctbind pub o|o !app app_fctbind pub o|o !ren ren_fctbind pub - ! show_fctbind pub - !stored stored_cmds setudef flag learn if {[file exists $dirname] == 0} {    file mkdir $dirname} proc create_db { dbname definfo } {    if {[file exists $dbname] == 0} {        set crtdb [open $dbname a+]        puts $crtdb "$definfo"        close $crtdb    }} proc readdb { rdb } {    global dbout    set fs_open [open $rdb r]    gets $fs_open dbout    close $fs_open} proc add_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return                      }           set txt [split $arg]     set cmd [string tolower [lindex $txt 0]]     set msg [join [lrange $txt 1 end]]     if {$msg != ""} {        if {[file exists $dirname/$cmd] == 0} {            create_db "$dirname/$cmd" "$msg"            putquick "NOTICE $nick :'$cmd' has been added"        } {            putquick "NOTICE $nick :'$cmd' is already defined"        }    } {        putquick "NOTICE $nick :use: !add &lt;cmd_name&gt; &lt;info&gt;"    }} proc show_fct { nick uhost hand chan arg } {    global dbout dirname     if {![channel get $chan learn]} {        return    }     set txt [string tolower [split $arg]]     set cmd [lindex $txt 0]     if {$cmd != ""} {        foreach files $txt {            if {$files != ""} {                if {[file exists $dirname/$files] == 1} {                    readdb $dirname/$files                    putquick "PRIVMSG $chan :$files: $dbout"                } {                    putquick "NOTICE $chan :'$files' doesn't exists"                }            }        }    } {        putquick "NOTICE $nick :use: ? &lt;cmd_name&gt; ... &lt;cmd_name&gt;"    }} proc del_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set all_files [glob -tails -directory $dirname -nocomplain -type f *]       set txt [string tolower [split $arg]]         set cmd [lindex $txt 0]     if {$cmd != ""} {        if {$cmd == "all_cmds"} {            foreach xfiles $all_files {                file delete $dirname/$xfiles                putquick "NOTICE $nick :all commands have been deleted"            }        }         if {$cmd != "all_cmds"} {            foreach files $txt {                if {$files != ""} {                    if {[file exists $dirname/$files] == 1} {                        file delete $dirname/$files                        putquick "NOTICE $nick :'$cmd' command has been deleted"                    } {                        putquick "NOTICE $nick :'$cmd' doesn't exists"                    }                }            }        }    } {        putquick "NOTICE $nick :use: !del all_cmds or !del &lt;cmd_name&gt; ... &lt;cmd_name&gt;"    }} proc rep_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set txt [split $arg]         set cmd [string tolower [lindex $txt 0]]         set msg [join [lrange $txt 1 end]]     if {$msg != ""} {        if {[file exists $dirname/$cmd] == 1} {            file delete $dirname/$cmd            create_db "$dirname/$cmd" "$msg"            putquick "NOTICE $nick :'$cmd' has been replaced"        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !rep &lt;cmd_name&gt; &lt;new_info&gt;"    }} proc app_fct { nick uhost hand chan arg } {    global dirname dbout     if {![channel get $chan learn]} {        return    }       set txt [split $arg]       set start [lindex $txt 0]     set cmd [string tolower [lindex $txt 1]]     set app_info [join [lrange $txt 2 end]]     if {$app_info != "" } {        if {[file exists $dirname/$cmd] == 1} {                if {$start == "fb"} {                readdb $dirname/$cmd                file delete $dirname/$cmd                create_db "$dirname/$cmd" "$app_info $dbout"                putquick "NOTICE $nick :done"            }             if {$start == "fe"} {                    readdb $dirname/$cmd                file delete $dirname/$cmd                create_db "$dirname/$cmd" "$dbout $app_info"                putquick "NOTICE $nick :done"            }        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !app &lt;fb|fe&gt; &lt;cmd_name&gt; &lt;additional_info&gt; | fb - from the beginning; fe - from the end;"    }} proc ren_fct { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return        }     set txt [string tolower [split $arg]]         set old [lindex $txt 0]         set new [lindex $txt 1]       if {$new != ""} {        if {[file exists $dirname/$old] == 1} {            file rename $dirname/$old $dirname/$new            putquick "NOTICE $nick :'$old' has been renamed to '$new'"        } {            putquick "NOTICE $nick :'$cmd' doesn't exists"        }    } {        putquick "NOTICE $nick :use: !ren &lt;old_cmd_name&gt; &lt;new_cmd_name"    }} proc stored_cmds { nick uhost hand chan arg } {    global dirname     if {![channel get $chan learn]} {        return    }     set files [glob -tails -directory $dirname -nocomplain -type f *]     if {$files != ""} {        set names [join $files ", "]    } {        set names "none"    }     putquick "NOTICE $nick :stored commands: $names"} putlog "tklearn.tcl ver 0.6 by tomekk loaded"</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8470">FmX</a> — Fri Dec 25, 2015 2:40 pm</p><hr />
]]></content>
	</entry>
	</feed>
