Looking for:
Tclsh85.exe download

Updated the readme with some better text, added the Gow license, impr…. Jul 20, Apr 29, Adding default Bash configuration to set user’s home directory, and l…. Apr 26, Added PuTTy 0. Remove repeated “of”. Aug 11, View code. It’s awesome. Shell window from any directory: Adds a Windows Explorer shell window so that you can right-click on any directory and open a command cmd. Stable binaries: All commands are kept up to date but also as stable as possible. Ousterhout in Why would someone bother to create their own language?
John and his students created a set of tools for designing integrated circuits at the University of California at Berkeley. Many of these tools had their own dedicated command languages, allowing interaction with the user. As the primary focus was on the tools, the command languages were often weakly designed, with odd syntax.
With the passing of time, the team realized they were missing an easy-to-use, simple, and embeddable common command language that would allow various tools to have a unified command syntax, and it was only a matter of time before Tcl came into existence. Consider building a complex application similar to the task of building a house.
All you need are bricks of different shapes and functionality, and some kind of substance such as filler or glue to keep it all together. This filler is Tcl, and the bricks are components exposed as commands. What more, you can use bricks components provided by someone else like factory , or you can create your own sophisticated bricks that will do whatever you need them to do, and all these bricks are still joined by the same substance—Tcl!
Now when creating your program, you do not have to ‘reinvent the wheel’ by implementing another to learn the error-prone command language—you can simply embed Tcl inside it. Tcl strongly supports and forces componentization of your application. It allows you to configure and control every application module so that it fits your needs.
Tcl is a scripting language with a UNIX-shell like syntax, where all operations are commands. Yes, let’s say that again—it’s all about the commands here. Everything in Tcl is a command. It comes with a set of built-in commands that implement basic ideas that every programming language simply has to have, namely variables, flow control, or procedures. But this is where the magic begins, as you will see later in the second chapter, the flexibility of Tcl allows us to easily extend it with object-oriented programming concepts.
Tcl is a dynamic scripting language—this means the source code you write using Tcl is not compiled in to binary file that may be executed on its own. On the contrary, it is stored ‘as is’—in form of a set of instructions commands written in one or more plaintext files, interpreted at runtime by the Tcl interpreter. The interpreter is nothing more than a normal binary application that can understand and process scripts it is provided with. A support for a specific platform means that there is an interpreter for this platform.
Each running Tcl interpreter should be considered as a separate virtual machine having its own internal state that is consequently modified by subsequent commands read from standard input.
The commands can also be read from the file, so you can execute your existing script, which will eventually lead the virtual interpreted machine to a new state and then interact with it dynamically.
It is possible to use Tcl entirely in an interactive manner by entering commands manually instead of executing an earlier created script. This ability adds great flexibility into both experimenting with and rapidly developing the code. This shell application is commonly called tclsh , but for example, in case of the ActiveTcl distribution described later in this chapter , the name tclsh85 is used to reflect Tcl version it supports.
The following screenshot illustrates the shell’s start as well as the execution of some basic commands:. The Tcl command info patchlevel returns Tcl’s version information and exit terminates the interactive interpreter shell. As Tcl scripts are nothing more than plaintext files, you do not need any special tools to develop them. All you need is a text editor with which you can create or modify Tcl files. If tclsh is executed with the filename, the shell is not shown, and the interpreter executes the script that is read from that file.
The following screenshot illustrates this:. The script file called main. Its content is the very much used “Hello World” example:.
The first line demonstrates how comments are made in Tcl—it starts with the character, and the second line contains the command put with the string attribute enclosed within quotation marks. This command will send the provided string to standard output. Along with tclsh comes another application called wish , which basically has the same functionality.
The main difference is that it preloads the Tk package and, in case of MS Windows, creates a separate window-based shell rather than using the system console.
Early implementations of Tcl interpreters were internally based on string representation of executed script that resulted in sluggish execution and poor speed. Such a byte code representation of the script is next executed by the interpreter, which significantly improves its performance. It is also possible to save compiled script for future usage, with the typical extension.
The main benefit to using bytecode files is that the source code is hidden—it does not give any real performance improvements. Based on what we discussed till now, any Tcl program consists of one or more scripts plus an interpreter.
Such a form allows easy and rapid development, meaning that you simply need to modify one of your scripts with text editor, but it also has its own drawbacks. It is much easier to distribute your program as a standalone, ready-to-execute binary file. Distribution of Tcl source files would be really awkward—for example, you may be not able to install the interpreter because of your system administrator’s policy.
Besides, how many times have you wanted to try out some interesting Java application only to get angry when you realized that to run it, you have to download dozens of megabytes and install Java virtual machine? If you consider this a “not so elegant” solution and are in favor of standalone applications, here is the good news—it is possible to pack all your scripts along with the interpreter into one binary, executable file that is not different from “normal” applications!
We will discuss this in more detail in Chapter 3. Tcl language is a standard example of an open source idea. Both Tcl and Tk are maintained by a world-wide community lead by the group of experts composing Tcl Core Team. One of the most significant contributors is a Canadian Software Company called ActiveState , which specializes in dynamic languages.
It provides its own distribution of Tcl called ActiveTcl and also offers various development tools both of these are discussed later in this chapter. Across this book, we will present Tcl in its latest available version, which is 8. However, majority of information is valid for the version 8. To sum it all up, Tcl is a mature scripting language with a lot of extensions coming from the open source community, and it allows you to quickly develop multi-platform command-line or GUI-based applications.
The great flexibility of Tcl comes from its ability to extend the available set of commands known to the interpreter by adding additional extensions, that is, Tcl packages. It is possible that a package will consist of both of these.
There are a lot of packages available on the Internet, both free of use and commercial. A good place to start is Tcllib—Tcl Standard Library. Soon you will notice that we will use various packages from this repository for the examples in this book. What’s more interesting is that if you find out that nobody created an extension you would like to use, you will be able to create your own one and share it with the community.
One of the extensions this chapter will cover is Tk, which was developed by John Osterhout. In other words, it is a library that contains a set of typical basic elements widgets such as buttons, frames, a canvas, menus, and so on. Tk widgets are flexible in terms of their customization options; almost every aspect may be defined at time of creation or modified later. As over the years, Tk appearance started to fall behind the looks of modern operating systems, a number of extensions were created.
Tile is also an engine that allows the usage of themes. According to the Tile documentation:. A theme is a collection of elements and styles that determine the look and feel of the widget set.
Tile has been incorporated into Tk core functionality in version 8. Although many Tk widgets have corresponding newer Tile equivalents, they can coexist in one application and the developer has the freedom of choice as to which version to use. As an example, have a look at the following screenshot of SnackAmp that illustrates Tcl’s possibilities in the field of GUI applications:.
Tk became so popular that it is no longer Tcl-specific. It is now possible to use it in other scripting languages like Perl or Python. Typically, you don’t want to waste your time doing this, especially when someone has done it before, and the fastest and easiest way is to get precompiled binaries for your platform. Among the various distributions of Tcl, ActiveTcl is considered as one of the best.
Not only does it contain Tcl and Tk, but it also offers a large number of extensions. As almost every Linux distribution comes with its own set of Tcl binaries, users of these systems usually have more choices. In the case of Microsoft Windows, ActiveTcl is substantially the only choice. Installation is simple; the installer is distributed in the form of an executable file named as something like ActiveTcl8. Once you download and run it, you will be presented with a graphical installation wizard similar to the one shown in the following screenshot:.
On subsequent screens, you will be presented with a detailed ActiveTcl License. You will also be able to specify installation directory—associate the application with the. It allows you to execute commands like tclsh Note that, as usual, you are advised against using a path containing whitespaces. We will consider Unix-compatible systems using Ubuntu 9. In the case of these systems, you have more choices than you do with Windows. One of the choices you have is to install ActiveTcl there is a good chance it supports your platform , another is to search for a precompiled Tcl distribution.
Ubuntu, for example, comes with a significant number of optional packages of additional software prepared by the community. Among them are of course binary compilations of Tcl. It is possible that your system already has the Tcl distribution installed, but even if not, it is extremely easy to install it, because Ubuntu will be able to suggest what packages should be installed based on the commands that these packages provide for the system.
The following is a screenshot of such a situation:. The user wants to execute the tclsh command to get Tcl interactive shell. The package that provides this command is not yet installed, and the system informs the user what packages are available.
In this case, we have decided to choose tcl8. Once installed, you can run the tclsh command to get the interactive Tcl shell as follows:. To verify the detailed version of Tcl interpreter which you have just installed, use the info patchlevel command. Tk comes in a separate Ubuntu package. You will be notified of this if you attempt to run an application that requires it, for example wish. Similarly, it can be installed with:. Just like core Tcl installation, extensions, that is Tcl packages, can also be installed in two ways: the first is to get the source code of an extension and build compile it, and the second one is to find, download, and install a pre-built package.
In order to be able to use the extension in your script, it must be available for the interpreter. You can learn its value by starting the Tcl shell and executing the following command:. The puts command prints the content of the specified variable to standard output. In the case of Windows, the output appears as:.
ActiveTcl comes with a handy utility called Teacup. This utility allows for easy installation of prebuilt Tcl extensions from external remote repositories called Tcl Extension Archives. These archives, also known as Teapot , are centrally managed sites. Currently, there is one public Teapot maintained by ActiveState.
By using Teacup, you can install the package you need into your local repository and then use it in your scripts. It will automatically solve dependencies, localize package s , and download and install them. In these days of rapid application development, using plaintext editors like notepad or vi can be really inconvenient and time consuming.
IDEs are tools that allow efficient code creation and editing, support testing your code from within the editor, and usually also offer debugging capabilities. Both support syntax highlighting and coloring, auto completion, creating launch configurations, managing projects and dependencies, and have many other useful features. It is hardly possible that you have not heard about Eclipse nowadays.
An open source IDE supporting a wide variety of languages, extensible with plugins is considered as one of the best programming environments, and it is all free.
We will discuss Eclipse Classic 3. The installation process is simple—just download and unzip the file to a location of your choice and run eclipse. The full description of Eclipse is out of scope of this book, we will present only the necessary steps to get it running for Tcl development purposes. In order to do this it, you have to navigate to the Help Install New Software… menu.
A new window will show up, as shown in the following screenshot:. First, select the Galileo site from the list at the top. Eclipse will download a list of all available extensions from this site; this may take a while.
Once you click on Next , Eclipse will automatically resolve dependencies and select all the necessary plugins to install. Following this, Eclipse will download and install all the necessary files, and ask you to restart.
Once it is done, you have to configure installed Tcl interpreters. Eclipse requires at least one interpreter in order to be able to run scripts. To configure it, navigate to Window Preferences to open the preferences dialog, and then go to Tcl Interpreters. Once done, you should have configured the default interpreter like here, as shown in the following screenshot:.
Now you have your Eclipse fully configured to create and run Tcl scripts! To get a taste of working with Eclipse, let’s create the same Hello World example. The next step is to right-click on the project name in this view and select Tcl File , and name it main. As a template, select Tcl File. Eclipse will create the file with a specific header that we will explain later. Add the puts command to that script, just as you did in the previous example.
Now it is time to execute the script—right-click on it and select Run As Tcl Script. The output of this execution will be visible in the Console view.
The following screen illustrates it:. The first one is a simple editor with syntax checking and coloring, and also Project Management abilities.
The second one extends the offered functionality as it comes with a debugger. Similar to Eclipse, you can create a project using File New New Project… and a file inside it right-click on project name in the left pane and select Add New file…. The new file is created based on a language-specific template, which comes with the universal header described later in this chapter.
If you find the standard Tcl shell too primitive, you must definitely have a look at tkcon —a standard console replacement with many useful features including a command history and syntax highlighting. What is even more interesting is that it is implemented as another Tcl package, and therefore it is perfectly possible to embed tkcon in to your Tcl application. Tkcon is, by default, included in the ActiveTcl distribution. For one, I completely missed the discussion on this, and just like others, seeing the lack of tclsh.
Seriously, Jeff, I’m not being negative about your work. I still think AT is an excellent distribution. It could have resembled this: Things to know when migrating from AT 8.
Also, starting from AT 8. This allows people to keep 8. Of course, if something in the above is inaccurate, feel free to correct it I understand. It’s just a matter of making the change of approach more visible. Nothing more. Not sure why you are implying I’ve been unconstructive; I feel this as rather unfair.
Now to answer your question, things I tend to depend on are just Snack and Img. I realize this is due to my specific context. I’m not ready to fight for their default inclusion. However, I’d love to see on the AT site: – either a “fat” 8. While we don’t expect anyone to follow the alphas, it’d be nice if people especially package maintainers did start testing things when we start declaring betas, since that lets us get the final release right.
OTOH, experience teaches that many people don’t try anything at all until the final release; that’s why patch releases are often forthcoming after not that long after a.
What about a half-fat “semi-skimmed”? Mind you, the idea of having an option in the installer to pull packages from the teapot is a nice one. Part of that’s addressable through teapot profiles, if I’ve grokked the listings and help messages right.
On the other hand, they’re currently harder and slower to use than they should be; harder because any introspection automatically adds a lot of information about packages and profiles I’m not interested in wrong platform or obsolete and slower because for some reason there’s no actual caching of metadata.
The first problem is really to do with who the intended audience of teacup is individual users or sysadmins and the second problem is something I hope will be fixed. Sure — but what the heck is a teapot profile? It may be of excellent quality, that’s not the issue. It is simply lacking a proper introduction. In the AT8. I don’t think so. You are welcome to download everything and install it yourself. You are not forced to do anything. If the documentation is lacking If you find a bug.
Log it. I logged 4 in my first outing with teacup. Hi I’m also a bit miffed, having been used to the straight forward install of previous releases 8. I try to encourage people at work to use Tcl for test automation, often quoting, “just do package require xyz”.
Now, once I’ve managed to create a repository on the machine and linked in correctly I have to explain the usage of teacup. This is a system admin job, if I hand it over to them it will take weeks to get anything done!. I should be comfortable with this approach, after all I do like my Ubuntu installation, but I find AT8.
I see it as another excuse for people to not bother trying Tcl if takes effort just too install it. I’ll be sticking to 8. Hopefully, you will get over being miffed and use 8. A good feature request would be to include some standard stuff like tcllib. I was annoyed at first but don’t let that take your focus off of helping.
Hi I have put “Batteries included release” on the 8. I wouldn’t have minded as much if they had the default repository to be the install directory but now I have to manipulate things and I’m not sure if I’ll be missing anything. I wonder if you can link the bin in the install to the apps directory and the lib to the packages directory of the teacup The whole thing starts to generate a lot of admin type questions that were not there before.
A benefit of including the “batteries” is that it brings a better understanding of what Tcl can do for the casual user. Very often I have tried packages because they were there and found a use for them. AS have already said that there’ll be a release of their build of 8. At a guess as someone who’s not at all affiliated it’s more of a QA and staff time issue than anything else.
So I would think that a list that really covers every significant area of application of Tcl will get you pretty much back to the original “batteries included” list. As people are pointing out, it has significant benefits, especially making it really easy to work with people who wouldn’t have chosen Tcl at the outset.
Thanks, Eric. I also realized that my post was kind of whining. I should add that I really appreciate what AS provides and the idea behind teapot. It’s just that my first reaction was to feel a bit depressed about having a more limited distro, because of the potential for a fat batteries-included distro to get folks interested in Tcl. I am sure there is some consensus that could be made. I would go for: tcllib tklib sqlite tkcon anything needed for starkits That would be my “bare minimum”.
I’ve answered this in some other thread recently, but to reiterate there are a couple key issues. Too many redundant packages that did the same thing. This leads to maintenance headaches for us and choice headaches for users. The teapot didn’t exist for 8. People need to get used to it, and you could call this the cold shower approach. The BI isn’t being dropped, it is being put on a diet. My bad. I have started using it so the cold shower worked.
For myself, it works and works well. And I think AS have done a good job of it, sorting out a lot of devilishly nasty issues. The metadata lack of caching problem is the only big issue that’s irritated me so far. OK, it could do with a GUI front-end. Someone’s weekend project perhaps? With RH, I’d say the “cold shower” worked for me. If it catches on, maybe it will be the calling card for Tcl that I can use to interest other developers. Note also that Andreas is currently on vacation, so nothing can be dealt with immediately.
Now is the best time to reflect on what is there and consider what you really really want in a BI. What about simply making several differently-sized “battery packs”? One of them would be “Everything” i. I don’t think I would push more than one ActiveTcl distro on Activestate. Everything else is brought down with teacup. Forget why we are talking about all this? I think he is right Creating such distros is not very complicated, but making sure that they will always work and fit together in the long term My vote is also for one AS distro, including tcllib.
But, again, it would be really cool to have a [package require] that downloads missing packages automatically from a teapot repository network connection and correct setup assumed. Not distribs, just subsets of the teapot, at any given time, to be downloaded more efficiently than one-by-one by teacup.
Tcllib is your choice. Others differ. I never use it. I rather depend on extensions. Not two people will depend on the same set. That makes a strong case for a 8. Another argument that gets my sympathy is that during the 8. A full battery pack has tremendous pedagogic value. Um no. It isn’t full circle at least I don’t think so in the way you think. I think tcllib is the minimum to include and maybe 3 or 4 max more. Everything else should be gotten via teacup.
With the most gracious possible nod to ActiveState for providing ActiveTcl, I have to say that announcing this distribution as 8. Like others, I have not followed all the betas carefully and only popped my head up when I noticed, at my supervisor’s prodding, that 8.
Gow Gnu On Windows is the lightweight alternative to Cygwin. It uses a convenient Windows installer that installs about extremely useful open source UNIX applications compiled as native win32 binaries. It is designed to be as small as possible, about 10 MB, as opposed to Cygwin which can run well over MB depending upon options.
Please submit feedback via the Gow issue tracker. Skip to content. Star 6. Unix command line utilities installer for Windows. This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. Branches Tags. Could not load branches. Could not load tags.
Latest commit. Git stats 15 commits. Failed to load latest commit information. Feb 15, Initial import of the code I developed back in Nothing has been…. Jul 14, Updated the readme with some better text, added the Gow license, impr…. Jul 20, Apr 29, Adding default Bash configuration to set user’s home directory, and l…. Apr 26, Added PuTTy 0. Remove repeated “of”. Aug 11, View code. It’s awesome. Shell window from any directory: Adds a Windows Explorer shell window so that you can right-click on any directory and open a command cmd.
Stable binaries: All commands are kept up to date but also as stable as possible. Copyright c – Brent R. About Unix command line utilities installer for Windows. Releases 5 Gow 0. Packages 0 No packages published. Contributors 3 bmatzelle Brent Matzelle SaqibS oliverpool. You signed in with another tab or window.
Reload to refresh your session. You signed out in another tab or window.
I just tried to upgrade to ActiveTcl 8. I uninstalled ActiveTcl 8. I recall that these packages were missing also from ActiveTcl 8. Initially, I thought that I had to use the teacup interface to retrive them from a repository, but my attempts failed to install anything, because the teacup exe tries to execute “tclsh. What am I missing? How is ActiveTcl 8.
I had the same problem. I copied the tclsh8. I think it was a mistake for ActiveState to do that but the reply I got back from support is that is the way it is for this release. Why would you require teacup to use tclsh. I have it fixed now and hope they fix it in the next release.
Currently I recommend installing it next to 8. This is a fully acceptable install, as 8. The teacup trying to use tclsh Please file a bug for it, with the invocation that caused it. I emailed support and they said it wasn’t a bug but a “QA decision”.
Ah well I too was so happy to get the 8. Or do you have a schedule for a fleshier release? Also, why now name the executable “tclsh I have dozens of. It is not really fun to modify all of them at each release. The unnumbered, generic command name is then set up as a link to the real executable file. This has the benefit of allowing multiple versions of a program to be installed, with the ability for a user script either to specify which one should be used, or to run “whichever is latest” by using the generic name.
Don’t modify all your scripts. Just modify the thing they point to, either by making a symbolic link or by copying the executable to the desired name. You would have to ask the QA team at ActiveState. I don’t agree with the reasons I got back but I don’t drive ActiveTcl. Yup, unless you’re in Windows where no such thing as a link exists. Of course I can copy tclsh So why just now? But surely it must be trivial to simply copy tclsh Watch it. I’m merely asking for a clear statement, from soemone who knows, not someone who guesses, as to how the migration is supposed to work out-of-the box on Windows.
Is it too much to ask? That is what I did. That isn’t the underlying issue. What if someone doesn’t “know” to do that? To them it is just broken. This isn’t the first release of AT 8.
This shouldn’t be that big a surprise, as this has been discussed since first release of the AT 8. The 8. We have a schedule for a fleshier release should be Q1’08 , but it won’t ever be as fleshy as 8. The versioned tclsh has to do with a possible conflict with 8. However, these days most computers are connected to the internet.
I think it would be nice if we could somehow tweak “package require” so that when a package is not found and an error is returned, the user is directed on what to execute in order to install the missing package.
Something like ubuntu linux does when you type a command that is not installed, but exists in a package: it provides with a description on the command needed to install the missing package along with the name of the package.
So, when for example a “package require tcllib” fails, the error message can be something like: can’t find package tcllib Please use “teacup blablabla tcllib” to see if the package “tcllib” is available in the teacup repositories, and “teacup install tcllib” to install it, if it is available.
At least this will give some hints to the ignorant user on how to get the missing packages. This gui should be somewhere in the menus created during the installation, and preferably run automatically after the installer exits. But give the user the option to run it at any time desirable.
Another option for those who have computers without internet connection is to have a second distribution which will install only the packages that we were used with 8. So as these users can download the 8. Now, regarding the packages I find completely useful and I want them to exist out of the box in 8. But I really would like ALL the 8. But I really won’t like to say to anyone install 8. I filed 4 bugs for teacup Friday. The rest is easy with teacup. Hmm, ok I can install Itk I would say that a bare minnimum is maybe tcllib.
On other aspects – would it make sense to override [package require], so that it automatically fetches a package if it is not available? From my point of view, tcllib is a minimum. Then, what about those packages used by TkSQLite? I would asume bare minimum is something like: tcllib tklib tkcon Some other stuff would probably be nice and expected, e. Best would be if that could also create a package bundle, so no online connection is needed to deploy it to several machines.
Would not be too different from creating a starkit with TDK right now, but without the wrapping up. Oh — so all users of Tcl are supposed to follow all the betas, and discussions on c. That’s news to me. For one, I completely missed the discussion on this, and just like others, seeing the lack of tclsh. Seriously, Jeff, I’m not being negative about your work. I still think AT is an excellent distribution.
It could have resembled this: Things to know when migrating from AT 8. Also, starting from AT 8. This allows people to keep 8. Of course, if something in the above is inaccurate, feel free to correct it I understand.
It’s just a matter of making the change of approach more visible. Nothing more. Not sure why you are implying I’ve been unconstructive; I feel this as rather unfair.
Now to answer your question, things I tend to depend on are just Snack and Img. I realize this is due to my specific context. I’m not ready to fight for their default inclusion.
However, I’d love to see on the AT site: – either a “fat” 8. While we don’t expect anyone to follow the alphas, it’d be nice if people especially package maintainers did start testing things when we start declaring betas, since that lets us get the final release right.
OTOH, experience teaches that many people don’t try anything at all until the final release; that’s why patch releases are often forthcoming after not that long after a. What about a half-fat “semi-skimmed”?
Mind you, the idea of having an option in the installer to pull packages from the teapot is a nice one. Part of that’s addressable through teapot profiles, if I’ve grokked the listings and help messages right.
On the other hand, they’re currently harder and slower to use than they should be; harder because any introspection automatically adds a lot of information about packages and profiles I’m not interested in wrong platform or obsolete and slower because for some reason there’s no actual caching of metadata. The first problem is really to do with who the intended audience of teacup is individual users or sysadmins and the second problem is something I hope will be fixed.
Sure — but what the heck is a teapot profile? It may be of excellent quality, that’s not the issue. It is simply lacking a proper introduction. In the AT8. I don’t think so. You are welcome to download everything and install it yourself.
You are not forced to do anything. If the documentation is lacking
Tcl Tool Command Language is a very powerful and easy to learn dynamic programming language, suitable for a very wide range of uses. Tcl is regarded as one of the best-kept secrets in the software industry. This book gives you a hands-on experience on Tcl, helping you develop network-aware applications using this mature yet evolving language.
This book shows you how to create network-aware applications with Tcl language. Packed with practical examples, the book not only takes you through the implementation of network protocols in Tcl, but also key aspects of Tcl programming. The book starts with the basic element of Tcl programming as we take a look at the syntax and fundamental commands of the language.
To get us ready for network programming, we look at important Tcl features such as object-oriented programming, accessing files, packaging in TCL, event driven programming, and multithreaded applications. The book is really about network programming, and it will not let you down with its deep coverage of these topics. Of course we look at protocols, but there are plenty of practical examples to keep things moving along. The book explains Simple Network Management Protocol SNMP , which is often used for monitoring and gathering information from various devices, such as routers, gateways, printers and many other types of equipment.
The purpose of this chapter is to refresh your memory with some basic and fundamental information about Tcl—what it is, what it is not, and why it was created. It is not intended to make you learn Tcl from scratch or to replace or duplicate the official Tcl documentation—there are a lot of sources, both online and printed. However, it is to briefly summarize facts and allow the reader to easily “tune in” to the topic of the book.
If you are new to Tcl, after going through this chapter, you will have an overview of the language and its basics, and it would be a good idea to experiment with it, create your own scripts, and study sophisticated options for the described commands before proceeding to further reading.
If you are an experienced Tcl programmer, you can probably skip this chapter. This chapter discusses the origins of Tcl language—the fundamental idea behind its creation, why it was created, and what kind of problems it addresses. It presents Tcl concepts, describes the possibilities Tcl offers, and explains flexibility that comes from a choice of extensions available for use. We also learn about the license agreement it is distributed under and who is involved in this undertaking. The chapter also talks about a range of enterprise-level platforms supported by Tcl.
Its strength comes from the portability it offers. We briefly describe how to obtain a ready-to-use distribution to start your adventure with Tcl, along with its installation on both Windows and Unix environments. We also describe the tools you can use to develop your own code. To start doing this, nothing more than a plaintext editor is required.
Both Eclipse and Komodo are discussed, along with installation and configuration tips, and the creation and execution of your first script. After that, we come to Tcl’s syntax, giving you the basics of reading the code and creating your first scripts. Once you have read this, you will be able to understand the structure of the code, identify its blocks and particular instructions.
You will also get familiar with the basic data types and flow control structures offered by the language. Basically, Tcl is yet another scripting language. It was created by Professor John K. Ousterhout in Why would someone bother to create their own language? John and his students created a set of tools for designing integrated circuits at the University of California at Berkeley.
Many of these tools had their own dedicated command languages, allowing interaction with the user. As the primary focus was on the tools, the command languages were often weakly designed, with odd syntax. With the passing of time, the team realized they were missing an easy-to-use, simple, and embeddable common command language that would allow various tools to have a unified command syntax, and it was only a matter of time before Tcl came into existence.
Consider building a complex application similar to the task of building a house. All you need are bricks of different shapes and functionality, and some kind of substance such as filler or glue to keep it all together. This filler is Tcl, and the bricks are components exposed as commands. What more, you can use bricks components provided by someone else like factory , or you can create your own sophisticated bricks that will do whatever you need them to do, and all these bricks are still joined by the same substance—Tcl!
Now when creating your program, you do not have to ‘reinvent the wheel’ by implementing another to learn the error-prone command language—you can simply embed Tcl inside it. Tcl strongly supports and forces componentization of your application. It allows you to configure and control every application module so that it fits your needs.
Tcl is a scripting language with a UNIX-shell like syntax, where all operations are commands. Yes, let’s say that again—it’s all about the commands here. Everything in Tcl is a command. It comes with a set of built-in commands that implement basic ideas that every programming language simply has to have, namely variables, flow control, or procedures.
But this is where the magic begins, as you will see later in the second chapter, the flexibility of Tcl allows us to easily extend it with object-oriented programming concepts. Tcl is a dynamic scripting language—this means the source code you write using Tcl is not compiled in to binary file that may be executed on its own. On the contrary, it is stored ‘as is’—in form of a set of instructions commands written in one or more plaintext files, interpreted at runtime by the Tcl interpreter.
The interpreter is nothing more than a normal binary application that can understand and process scripts it is provided with. A support for a specific platform means that there is an interpreter for this platform. Each running Tcl interpreter should be considered as a separate virtual machine having its own internal state that is consequently modified by subsequent commands read from standard input.
The commands can also be read from the file, so you can execute your existing script, which will eventually lead the virtual interpreted machine to a new state and then interact with it dynamically. It is possible to use Tcl entirely in an interactive manner by entering commands manually instead of executing an earlier created script.
This ability adds great flexibility into both experimenting with and rapidly developing the code. This shell application is commonly called tclsh , but for example, in case of the ActiveTcl distribution described later in this chapter , the name tclsh85 is used to reflect Tcl version it supports.
The following screenshot illustrates the shell’s start as well as the execution of some basic commands:. The Tcl command info patchlevel returns Tcl’s version information and exit terminates the interactive interpreter shell. As Tcl scripts are nothing more than plaintext files, you do not need any special tools to develop them. All you need is a text editor with which you can create or modify Tcl files. If tclsh is executed with the filename, the shell is not shown, and the interpreter executes the script that is read from that file.
The following screenshot illustrates this:. The script file called main. Its content is the very much used “Hello World” example:. The first line demonstrates how comments are made in Tcl—it starts with the character, and the second line contains the command put with the string attribute enclosed within quotation marks.
This command will send the provided string to standard output. Along with tclsh comes another application called wish , which basically has the same functionality.
The main difference is that it preloads the Tk package and, in case of MS Windows, creates a separate window-based shell rather than using the system console. Early implementations of Tcl interpreters were internally based on string representation of executed script that resulted in sluggish execution and poor speed.
Such a byte code representation of the script is next executed by the interpreter, which significantly improves its performance. It is also possible to save compiled script for future usage, with the typical extension. The main benefit to using bytecode files is that the source code is hidden—it does not give any real performance improvements.
Based on what we discussed till now, any Tcl program consists of one or more scripts plus an interpreter. Such a form allows easy and rapid development, meaning that you simply need to modify one of your scripts with text editor, but it also has its own drawbacks. It is much easier to distribute your program as a standalone, ready-to-execute binary file. Distribution of Tcl source files would be really awkward—for example, you may be not able to install the interpreter because of your system administrator’s policy.
Besides, how many times have you wanted to try out some interesting Java application only to get angry when you realized that to run it, you have to download dozens of megabytes and install Java virtual machine?
If you consider this a “not so elegant” solution and are in favor of standalone applications, here is the good news—it is possible to pack all your scripts along with the interpreter into one binary, executable file that is not different from “normal” applications! We will discuss this in more detail in Chapter 3. Tcl language is a standard example of an open source idea.
Both Tcl and Tk are maintained by a world-wide community lead by the group of experts composing Tcl Core Team. One of the most significant contributors is a Canadian Software Company called ActiveState , which specializes in dynamic languages. It provides its own distribution of Tcl called ActiveTcl and also offers various development tools both of these are discussed later in this chapter.
Across this book, we will present Tcl in its latest available version, which is 8. However, majority of information is valid for the version 8. To sum it all up, Tcl is a mature scripting language with a lot of extensions coming from the open source community, and it allows you to quickly develop multi-platform command-line or GUI-based applications.
The great flexibility of Tcl comes from its ability to extend the available set of commands known to the interpreter by adding additional extensions, that is, Tcl packages. It is possible that a package will consist of both of these.
There are a lot of packages available on the Internet, both free of use and commercial. A good place to start is Tcllib—Tcl Standard Library. Soon you will notice that we will use various packages from this repository for the examples in this book.
What’s more interesting is that if you find out that nobody created an extension you would like to use, you will be able to create your own one and share it with the community. One of the extensions this chapter will cover is Tk, which was developed by John Osterhout. In other words, it is a library that contains a set of typical basic elements widgets such as buttons, frames, a canvas, menus, and so on.
Tk widgets are flexible in terms of their customization options; almost every aspect may be defined at time of creation or modified later. As over the years, Tk appearance started to fall behind the looks of modern operating systems, a number of extensions were created.
Tile is also an engine that allows the usage of themes. According to the Tile documentation:. A theme is a collection of elements and styles that determine the look and feel of the widget set.
Apr 26, Added PuTTy 0. Remove repeated “of”. Aug 11, View code. It’s awesome. Shell window from any directory: Adds a Windows Explorer shell window so that you can right-click on any directory and open a command cmd. It’s just a matter of making the change of approach more visible.
Nothing more. Not sure why you are implying I’ve been unconstructive; I feel this as rather unfair. Now to answer your question, things I tend to depend on are just Snack and Img. I realize this is due to my specific context. I’m not ready to fight for their default inclusion. However, I’d love to see on the AT site: – either a “fat” 8. While we don’t expect anyone to follow the alphas, it’d be nice if people especially package maintainers did start testing things when we start declaring betas, since that lets us get the final release right.
OTOH, experience teaches that many people don’t try anything at all until the final release; that’s why patch releases are often forthcoming after not that long after a. What about a half-fat “semi-skimmed”? Mind you, the idea of having an option in the installer to pull packages from the teapot is a nice one. Part of that’s addressable through teapot profiles, if I’ve grokked the listings and help messages right.
On the other hand, they’re currently harder and slower to use than they should be; harder because any introspection automatically adds a lot of information about packages and profiles I’m not interested in wrong platform or obsolete and slower because for some reason there’s no actual caching of metadata.
The first problem is really to do with who the intended audience of teacup is individual users or sysadmins and the second problem is something I hope will be fixed.
Sure — but what the heck is a teapot profile? It may be of excellent quality, that’s not the issue. It is simply lacking a proper introduction. In the AT8. I don’t think so. You are welcome to download everything and install it yourself.
You are not forced to do anything. If the documentation is lacking If you find a bug. Log it. I logged 4 in my first outing with teacup. Hi I’m also a bit miffed, having been used to the straight forward install of previous releases 8.
I try to encourage people at work to use Tcl for test automation, often quoting, “just do package require xyz”. Now, once I’ve managed to create a repository on the machine and linked in correctly I have to explain the usage of teacup.
This is a system admin job, if I hand it over to them it will take weeks to get anything done!. I should be comfortable with this approach, after all I do like my Ubuntu installation, but I find AT8. I see it as another excuse for people to not bother trying Tcl if takes effort just too install it. I’ll be sticking to 8. Hopefully, you will get over being miffed and use 8.
A good feature request would be to include some standard stuff like tcllib. I was annoyed at first but don’t let that take your focus off of helping. Hi I have put “Batteries included release” on the 8. I wouldn’t have minded as much if they had the default repository to be the install directory but now I have to manipulate things and I’m not sure if I’ll be missing anything. I wonder if you can link the bin in the install to the apps directory and the lib to the packages directory of the teacup The whole thing starts to generate a lot of admin type questions that were not there before.
A benefit of including the “batteries” is that it brings a better understanding of what Tcl can do for the casual user. Very often I have tried packages because they were there and found a use for them. AS have already said that there’ll be a release of their build of 8. At a guess as someone who’s not at all affiliated it’s more of a QA and staff time issue than anything else. So I would think that a list that really covers every significant area of application of Tcl will get you pretty much back to the original “batteries included” list.
As people are pointing out, it has significant benefits, especially making it really easy to work with people who wouldn’t have chosen Tcl at the outset. Thanks, Eric. I also realized that my post was kind of whining. I should add that I really appreciate what AS provides and the idea behind teapot. It’s just that my first reaction was to feel a bit depressed about having a more limited distro, because of the potential for a fat batteries-included distro to get folks interested in Tcl.
I am sure there is some consensus that could be made. I would go for: tcllib tklib sqlite tkcon anything needed for starkits That would be my “bare minimum”.
I’ve answered this in some other thread recently, but to reiterate there are a couple key issues. Too many redundant packages that did the same thing. This leads to maintenance headaches for us and choice headaches for users.
The teapot didn’t exist for 8. People need to get used to it, and you could call this the cold shower approach. The BI isn’t being dropped, it is being put on a diet. My bad. I have started using it so the cold shower worked. For myself, it works and works well. We can execute the same without Komodo IDE. However, Komodo provides additional features such as variable type viewer, debugging using break points etc.
Following are some online tools I Prefer most to compile and cross verify the. Note – If any example is not working or any links are not working, please comment I will update with appropriate ones…. This assumption is not verified by this script. The temporary directory specified in the TEMP or TMP environment variables must refer to an existing directory writable by the current user.
The “zip” and “unzip” command line tools must be located either in a directory contained in the PATH environment variable or specified as the exact file names to execute in the “ZipTool” and “UnZipTool” environment variables, respectively. The template VSIX file which is basically a zip file must be located in a “win” directory inside the directory containing this script. It should not contain any executable binaries.
The new file is created based on a language-specific template, which comes with the universal header described later in this chapter. If you find the standard Tcl shell too primitive, you must definitely have a look at tkcon —a standard console replacement with many useful features including a command history and syntax highlighting. What is even more interesting is that it is implemented as another Tcl package, and therefore it is perfectly possible to embed tkcon in to your Tcl application.
Tkcon is, by default, included in the ActiveTcl distribution. To install it on Ubuntu, enter:. Tcl scripts are nothing more than plaintext files saved with bit Unicode encoding. Such a script consists of one or more commands that are executed by the interpreter at runtime. Each line of the script with exceptions described as follows consists of the command and zero or more command arguments, all separated by whitespaces spaces or tabs. If the line starts with the character, it is considered to be a comment and not processed by the interpreter.
This is useful for breaking long lines and improving the readability of the code. You can also join separate commands using ;, as shown in the following example:.
The comprehensive documentation for Tcl 8. This section does not intend to replace or compete with it, but to briefly introduce Tcl’s grammar and rules. Therefore, we strongly recommend reading the documentation, especially the descriptions of the main commands.
Let’s revisit the main. The first line is the comment. The second line has the puts command with one parameter —the text string—in quotations marks. As we mentioned previously, you can run the script with:. However, in some cases, it would be far more comfortable to run it as a standalone program.
On Windows, you can associate the. On Unix, the script will look like:. The first line starts with the! The presence of these two characters at the very beginning of the executable file informs the system’s program loader that the file is a script and also specifies the interpreter which should be used to run it.
As the character itself is often a comment marker, the line will be ignored by the interpreter. However, it is not a good idea to hardcode the path, because it may be different for other systems, thus making our code not non-portable.
A better solution is:. In this case, the script is interpreted by standard sh shell. This shell is unable to run Tcl commands, but it will run the exec command perfectly, effectively launching tclsh , passing the script name and other arguments if any. The trick is that we do not want the Tcl interpreter to process the exec command, as it was intended for sh only.
The env command searches for tclsh using system PATH variable and executes it, therefore, no direct path to it is required. It is worth mentioning that the shell offers hints about the syntax of any command. This is extremely useful if you don’t quite remember the required arguments or their order:. The syntax of such a hint is commonly used throughout the Tcl documentation.
Question marks indicate optional arguments in this example, nonewline or channelId are both optional. As with any other language, Tcl allows us to define variables. Let’s consider the following example:. The first command set creates a variable named myVariable and sets its value to somevalue.
The second command, that is puts , prints the variable’s value on the screen. When the interpreter starts processing the second line, it will first substitute all the variable values, so the line will effectively be puts “someValue” , and then it will execute it. This will result in the following output:. To delete a variable, use the unset command:.
In an earlier example, we used “” to group Hello world one more time! Without it, we would get a syntactical error, as each word would be treated as separate argument for the puts command:. The text inside quotation marks is processed before being passed to the command.
What this it means is that all references to variables are replaced with the variable’s values, for example:. The substitution gets complicated if you don’t want to have any whitespace between the variable’s value and the text that follows.
One more unique feature of curly braces is that they allow multiple lines inside them. In the code:. The new line character that terminates the first line is not processed, and therefore, it also breaks the output into two lines.
The ability to execute commands wouldn’t be very valuable if there wasn’t some way to provide the result of one command to another. In Tcl, we can use [] to execute a command and capture its return value:. In this example, the output of the info patchlevel command is used as the value for the var variable. It is also perfectly possible to use [] inside quotation marks, as its content will be processed by the interpreter:. Basically, every variable in Tcl can be considered as a string.
The internal representation of such a variable depends on its execution state see Chapter 2 , Advanced Tcl features for more details. Being a dynamic language, Tcl converts the value of a variable to a suitable type at runtime. We introduce the new Tcl command expr that allows arithmetic operations. In this example, the string “2” is converted to an integer by expr and it returns correct value, but the string text causes an error, because it cannot be converted. To operate on strings, the string command is extremely useful.
The convention of this command is that it accepts a subcommand name as the first argument. For example, if we assume that str is a Hello World! The String match command can be used to verify if the given string matches the pattern. The pattern is basically another string, but apart from normal characters, some special sequences can be also used:. Matches exactly one character, only that specified inside [] brackets.
It is possible to use the [a-z] syntax to match all characters in this range, in this case from ‘a’ to ‘z. Allows escaping of any of the special characters, such as? The command returns 1 if the string is successfully matched and it returns 0 otherwise:.
Note that in the last two cases, this pattern is put into curly braces to prevent the interpreter from considering the content of the [] braces as a command to be executed. It is worth mentioning at this point that depending on the context, the variable’s value may be treated as a text string, a number, or a logical value, just as we will see in the following examples.
More than pure strings, Tcl introduces the concept of two interesting data types—lists and arrays hashmaps. A Tcl list holds an ordered sequence of elements such as strings, other lists, and other variables. To create a list, you can use the list command:. In this example, we create a list using three elements, separated with whitespaces, and assign the list to the myList variable. What is interesting is that there is no straight demarcation between the list and the string, and therefore, the following code also creates a list:.
Curly braces are also possible here. The conclusion is that every string may be considered as a list.
The advantage of using the list command is that it takes care of correct formatting, adding braces and backslashes when necessary. Consider either of the following two commands:. They will create a list in which the third element will be another list consisting of elements specified in curly braces.
The same effect can be achieved using the list command:. From the user’s point of view, a list is both a string and a list, because there is no visible difference:. So why even bother with lists? Lists allow you to organize and structure your data, and the benefits of using them are that Tcl offers a set of commands that operates on lists. Lists tend to be extremely useful in typical scripts, therefore, we will briefly review the possible operations on them.
To get the number of elements in your list, use llength. This command takes one parameter, that is, the list. The output is the number of elements in the list.
Tclsh85.exe download.Process Library
Many hyperlinks are disabled. Use anonymous login to enable hyperlinks. Exactly one command line argument is required, the REM name of an existing directory to be used as the final destination directory REM for the generated output files, which will be placed in sub-directories REM created therein. Ideally, the directory specified should be empty. Neither of these REM variable values may contain any double quotes, surrounding or embedded. These values in these two variables should be surrounded by double REM quotes if they contain spaces.
There should be exactly one iteration per REM platform. Tcl 8. The “sqlite3. The [optional] second command line argument to this script may be used to specify an alternate location. This script also assumes that the “sqlite3. This assumption is not verified by this script.
The temporary directory specified in the TEMP or TMP environment variables must refer to an existing directory writable by the current user. The “zip” and “unzip” command line tools must be located either in a directory contained in the PATH environment variable or specified as the exact file names to execute in the “ZipTool” and “UnZipTool” environment variables, respectively.
The template VSIX file which is basically a zip file must be located in a “win” directory inside the directory containing this script. It should not contain any executable binaries. The executable and other compiled binary files to be packaged into the final VSIX file e. The top-level directory of the tree must be specified as the first command line argument to this script.
The second level sub-directory names must match those of the build configuration e. The third level sub-directory names must match those of the platform e. This includ es the sour ce and destination file names, build-neutral boolean flags, platform-neutral boolean flags, and the dynamic content subst boolean flags.
There is also one set of boolean flags per build configuration, currently “Debug” and “Retail”, that control which files are skipped for it.
This page was generated in about 0. Add detailed comments to the build tools used to generate the VSIX package. Also, allow the build configurations and native library directories to be overridden for the multi-platform build tool for MSVC.
Put auxiliary libraries after libsqlite3.
Jun 08, · As of this writing, MsysGit for Windows has latest version available for download. Eager to try out this new version, I decided to build it myself. Download MysysGit build environment for Windows from here git\bin\replace.me git\bin\tclshexe git\bin\tkexe. After copying these files. Tcl Standalone Binaries; Understanding the executable file structure; Learning the Metakit database; Learning more about virtual file systems; Learning Tclkit. Zip format. Tk Sources. replace.me Gzip format. replace.me Zip format. Other versions of the source distributions are available at SourceForge. For other ways to obtain Tcl/Tk (such as binary distributions), see the main Tcl/Tk page. The source releases include make files for Windows, Unix and Xcode project files for Mac OS X. Expect is a tool for automating interactive applications such as telnet, ftp, passwd, fsck, rlogin, tip, etc. Expect is also useful for testing these same applications. nsnam. Ns is a discrete event simulator targeted at networking research. Ns provides substantial support for simulation of TCP, routing, and multicast protocols over wired and.
Jun 08, · As of this writing, MsysGit for Windows has latest version available for download. Eager to try out this new version, I decided to build it myself. Download MysysGit build environment for Windows from here git\bin\replace.me git\bin\tclshexe git\bin\tkexe. After copying these files. Expect is a tool for automating interactive applications such as telnet, ftp, passwd, fsck, rlogin, tip, etc. Expect is also useful for testing these same applications. nsnam. Ns is a discrete event simulator targeted at networking research. Ns provides substantial support for simulation of TCP, routing, and multicast protocols over wired and. Aug 01, · Download iTunes for Windows (bit – for older video cards) Download the iTunes installer to your Windows desktop. Locate the replace.me and double click to run the installer. Install as you normally would. Your iTunes library will . Using awk allows you to: Manage small, personal databases. Generate reports. Validate data. Produce indexes and perform other document preparation tasks. Experiment with algorithms that you can adapt later to other computer languages. In addition, gawk provides facilities that make it easy to: Extract bits and pieces of data for processing. Jul 08, · Download ActiveState ActiveTcl for free. ActiveTcl is the leading commercial-grade distribution of the open source Tcl programming language. Windows Mac. EN The ActiveState ActiveTcl installer is commonly called tclshexe, tclshexe, replace.me, replace.me or replace.me etc. ActiveState ActiveTcl is sometimes referred to as “ActiveTcl /5(13).
Find centralized, trusted content and collaborate around the technologies you use most. Connect and share knowledge within a single location that is structured and easy to search.
What is the difference between tclsh85 executable and tclsh85s executable? I can find the both executable in Tcl Directory Thanks. They’re built from exactly tclsh85.exe download same source code, with almost identical options; they should be functionally indistinguishable to the enormous majority of tclsh85.exe download. The only difference is that tclsh85s.
You shouldn’t see any performance or functionality difference if you’re not tclsh85.exe download something that directly touches on the linking or redistribution of the code. Stack Overflow for Teams — Start collaborating and sharing organizational knowledge. Create a free Team Why Teams? Learn more. Ask Question. Asked 7 years ago. Modified 7 years ago. Viewed times.
Improve this question. Muhammed Abdelsalam Muhammed Abdelsalam 1 3 3 tclsh85.exe download badges. They should be the same I think. I forgot why there are copies tclsh85.exe download. The s version is usually statically linked, the normal tclsh85.exe download is dynamically linked. Tclsh85.exe download a comment. Sorted by: Reset to нажмите чтобы перейти. Highest score default Date modified newest first Date created oldest first.
Improve this answer. Donal Fellows Donal Fellows k tclsh85.exe download 18 gold badges silver badges bronze badges. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email winoncd 6 freeware download Password.
Post as a guest Name. Email Required, but never shown. The Overflow Blog. Episode Kidnapping an NFT. Featured on Tclsh85.exe download. Announcing the arrival of Valued Посмотреть больше Dalmarus. Improvements to site status and incident communication. Collectives Update: Introducing Bulletins. Should we burninate the [comma] tag?
Related Hot Network Questions. Question feed. Accept all cookies Customize settings.
It is designed to be as small as possible, about 10 MB, as opposed to Cygwin which can run well over MB depending upon options. Please submit feedback via the Gow issue tracker. Skip to content. Star 6. Unix command line utilities installer for Windows. This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. Branches Tags. Could not load branches. Could not load tags.
Latest commit. Git stats 15 commits. Failed to load latest commit information. Feb 15, Initial import of the code I developed back in Nothing has been…. Jul 14, Updated the readme with some better text, added the Gow license, impr…. Jul 20, Apr 29, These values in these two variables should be surrounded by double REM quotes if they contain spaces.
There should be exactly one iteration per REM platform. Tcl 8. The “sqlite3. The [optional] second command line argument to this script may be used to specify an alternate location. This script also assumes that the “sqlite3. This assumption is not verified by this script. The temporary directory specified in the TEMP or TMP environment variables must refer to an existing directory writable by the current user. The “zip” and “unzip” command line tools must be located either in a directory contained in the PATH environment variable or specified as the exact file names to execute in the “ZipTool” and “UnZipTool” environment variables, respectively.
The template VSIX file which is basically a zip file must be located in a “win” directory inside the directory containing this script. It should not contain any executable binaries. The executable and other compiled binary files to be packaged into the final VSIX file e. The top-level directory of the tree must be specified as the first command line argument to this script.
В главном банке данных происходит нечто странное. Джабба взглянул на часы. – Странное? – Он начал беспокоиться. – Можешь выражаться яснее.
Exactly one command line argument is required, the REM name of an existing directory to be used as the final destination directory REM for the generated output files, which will be placed in sub-directories REM created therein.
Ideally, the directory specified should be empty. Neither of these REM variable values may contain any double quotes, surrounding or embedded. These values in these two variables should be surrounded by double REM quotes if they contain spaces. There should be exactly one iteration per REM platform. Tcl 8. Sorted by: Reset to default. Highest score default Date modified newest first Date created oldest first.
Improve this answer. Donal Fellows Donal Fellows k 18 18 gold badges silver badges bronze badges. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. The command inserts new elements at the end of the specified variable and does not return the new list—instead, it is automatically set as the new value of the specified variable. This command can also be used to create new lists if the variable passed as the first argument does not exist.
The linsert command can be used to insert one or more elements into a list at the specified index. Unlike lappend , it takes the value of the list as its first argument, followed by the index to insert elements at and any number of elements to insert. The lset command allows you to replace the values of elements with new ones.
It accepts a variable name, and one or more indexes, followed by the new value to set. The changed list is stored back in the variable specified as the first argument. For example, we can specify a single index to modify the nth element of a list:. Similar to lindex , this command can access and modify elements of sub-lists. The lreplace command is also similar to it, but allows replacing a set of elements.
It accepts the list as the first argument, the start and end indexes to replace, and the new items to insert instead of the specified elements.
The command removes elements between start and end inclusively and inserts new items in their place. Like linsert , it does not alter an existing list, but returns a new one. In case you don’t specify new replacement items, the command will only remove elements within a range:. The lsort command can be used to sort lists in Tcl. It is also possible to modify the sorting order by specifying additional options, for example -decreasing:.
By default, the elements are compared as text values—therefore, when sorting 9, 10, 11, and, 2, the result would be 10, 11, 2, and 9. The following switches allow us to define how elements are compared, which affects the output of the sorting operation:. Compares elements using dictionary-style comparison; see the following paragraph for more details.
Dictionary-based sorting is similar to text-based comparison, except that character case is ignored here. An exception is when both the elements are the same, in that case, the uppercase elements are put before lowercase elements.
If strings contain numbers, they are compared as integers, not characters. For example, when sorting 9, 10, 11, and 2 using the -dictionary switch, the result would be 2, 9, 10, and We can also tell lsort to use all elements in the list as sub-lists and compare them only using specified elements of these sub-lists, by using the -index option. The value for the option can be a single index or a list of indexes, where each element of the index list indicates an index in a sub-list.
Another option is to use your own custom implementation of the comparison algorithm. To do so, you have to define a command that accepts two arguments items from the list that is being sorted and returns the integer value by complying to the following rules:. The value is negative when the first argument is considered to be lower than the second.
The value is 0 when both arguments are considered equal. The value is a positive value when the first argument is higher than the second one. We have the animals list that contains some animal names. The default implementation will sort it in the alphabetical order, but we will be able to define our own implementation in the form of the compareString procedure, which will sort it in the order of the word’s length:.
An interesting property of the lsort command is that when two elements are considered as the same, their order in the output is the same as the order in which they were taken as inputs. This can be used to sort lists of lists using multiple orders.
We need to sort the list by each element we want it to be sorted using, but in the reverse order. For example, we can sort a list where each element is a sub-list consisting of first name, last name, and age.
If we want to order it by the last name and the decreasing order of age for the same last names, we need to sort it by age first and later by the last name:. You can search through your list to find the element s that match your pattern using lsearch:.
This command looks for the element three in myList , and returns the index of the first occurrence of the searched element—3 or -1 if element is not found. It will be able to accept options such as:. The command lassign allows you to assign values from the list to different variables on a single line.
The first argument is a list, and the consecutive arguments are names of the variables. If there are more variables than list elements, the remaining elements will be set to empty strings. Another important data type for storing a set of values is an array. In Tcl, arrays are essentially associative maps, because any string value is permitted as an array key index. Consider the following example:. After looking at the first line, the interpreter knows that the myArray variable will be an array, because of presence of the braces.
Inside these braces, the array key key1 is written, and it is mapped to the string element1. We have three keys overall— key1 , key2 , and 3 note that the last one is different from the first two, but still valid —that point to three values: element1, element2 , and element3 respectively. The key name can contain any character, and also spaces of course, with the correct syntax, for example, by using the Esc key with a backslash.
To manipulate array variables, use the array command with the appropriate operator and arguments. The most common operations are:. The command array exists returns the value 1 only when the variable passed as an argument exists and is an array:. We can also delete a specified key or keys by specifying the pattern to match the keys that we want to delete as follows:.
This will delete all the elements of an array that starts with prefix ,. The list it returns consists of name-value pairs. This means that for each element in the array, this command returns its name as an element followed by its value as another element.
We can also use array get to get specific elements of an array, by adding a pattern to match keys, similar to array unset. To reverse this operation and set one or more keys in an array from the name-value pairs, we can use array set command:. Although arrays are popular and commonly used, there are some drawbacks to using them. They are not Tcl objects on their own, but rather a collection of variables, a way in which a particular variable name can store zero or more key-value relations:.
If we set an array key with the previous command, myarray is not a variable by itself, but rather each key and value pair is stored as a Tcl object. From the programming perspective, this has little impact. However, once you set an array, you cannot pass it as a variable; for example:. The preceding code will raise an error we will present return later in this chapter. However, it is okay to reference it via the variable name in commands such as upvar, variable , which are explained later throughout Chapter 2.
Also, only one dimensional arrays are supported—so the syntax like myArray 1 2 is incorrect. This can be bypassed by using some specific key name convention, for example with the ‘. Effectively, my3DArray can be treated as a three-dimensional array, with indexes separated by the character or string of your choice.
To address the previously mentioned drawbacks of arrays, a new data type was introduced, which is quickly gaining acceptance and popularity among Tcl developers— dictionary. Dictionaries are somewhat similar to arrays in that they keep mapping between key and value, but a dictionary is treated as an object.
Dictionaries can also be truly multi-dimensional. The other difference is that dictionaries are significantly faster than arrays. The new command dict was introduced to operate on dictionaries. The command is natively present in Tcl 8. To create a dictionary, use the dict create command with the equal number of arguments; alternately, keys and values:. The previous line creates a dictionary with three mappings and stores it in the myDict variable.
Here, in dictionary a , the key 1 is mapped to other dictionary which has key 2 mapped to the third dictionary, wherein key 3 is mapped to value. To access the mapped value, you can use the dict get command:. The second command’s invocation in this example demonstrates how to access a third-level variable. These are only the basics, there are also many other operations available for dictionaries, these can be compared to the operations for arrays described earlier, because their concepts are similar.
There is a separate command called expr that handles all mathematical and logical operations. The command accepts an expression to evaluate. An interesting detail is that this expression can be passed as one argument, or as unlimited number of arguments.
The following calls to expr will return the same result:. Like almost any other language, Tcl has a set of commands—conditional and iterational—to control the flow of the program. Depending on the boolean value of the condition variable, the first or the second part of the command is executed. In this case, the output is:. Note that the entire if command call could be written in one line:. The first argument is an expression representing a logical condition.
The value is evaluated in the same way as in case of the expr command. It is possible to skip else and the second script body, or to add more conditions by using elseif with another condition, and a script to execute in case the condition is true.
The second command switch allows us to decide what action should be taken based on the value passed; for example, consider the following example code:. As the value of value variable is second , the second script body is passed to the Tcl interpreter, resulting in the output second value on the screen.
It is possible to skip the default section. Also, more than one acceptable value separated by the character may be defined for each of the sections:. The values 1, 1st , or first will all match with the first section. Finally, it is possible to use patterns that we have used with string match command to match the appropriate section, by specifying the -glob option with the switch command:. In this case, both the values second and 2nd would match with the second option.
Tcl offers three commands that allow the iterational execution of code: for, while , and foreach. The first argument is a code snippet executed at the beginning of the loop in this example, it defines the counter variable x and initializes it with value 1.
The second one is a condition that is checked to be logically true before each loop if the counter is smaller than 4 and the third is the condition which is evaluated after each loop—in most cases, to increase the counter for example, using the command incr.
The last part of the statement is the body of the loop. The output of the example is:. The while command operates in a similar fashion, with the exception that the condition is evaluated after each loop, not before, and there is neither a start nor “after each loop” code section present. The equivalent of the previous example code written with while is:. The last command is foreach. The idea behind this command is to pass one or more lists, and the loop’s body is executed for every element of the list:.
The following example shows using two lists at the same time. Komodo uses the same executable to run the. We can execute the same without Komodo IDE. However, Komodo provides additional features such as variable type viewer, debugging using break points etc. Following are some online tools I Prefer most to compile and cross verify the. Note – If any example is not working or any links are not working, please comment I will update with appropriate ones….
Aug 05, · Download and install tcldll. Did you know? You may already have this file even though you are replace.me errors. That’s because replace.me file may have been moved or renamed by another application. Check to see if you already have tcldll on your computer. For more information see how to search your PC replace.me files. Using awk allows you to: Manage small, personal databases. Generate reports. Validate data. Produce indexes and perform other document preparation tasks. Experiment with algorithms that you can adapt later to other computer languages. In addition, gawk provides facilities that make it easy to: Extract bits and pieces of data for processing. Jun 08, · As of this writing, MsysGit for Windows has latest version available for download. Eager to try out this new version, I decided to build it myself. Download MysysGit build environment for Windows from here git\bin\replace.me git\bin\tclshexe git\bin\tkexe. After copying these files. Installation is simple; the installer is distributed in the form of an executable file (named as something like replace.me). Once you download and run it, you will be presented with a graphical installation wizard similar to the one shown in the following screenshot.
Tclsh85.exe download.GitHub – bmatzelle/gow: Unix command line utilities installer for Windows.
Selecting a language below will dynamically change the complete page content to that language. You have not selected any file s to download. A download manager is recommended for downloading multiple files.
Would you like to install the Microsoft Download Manager? Generally, a download manager enables downloading of large files or multiples files in one session.
Many web browsers, such as Internet Explorer 9, include a download manager. Stand-alone download managers also are available, including the Microsoft Download Manager. The Microsoft Download Manager solves these potential problems. It gives you the ability to download multiple files at one time and download large files quickly and reliably. It also allows you to suspend active downloads and resume downloads that have failed. Microsoft Download Manager is free and available for download now.
Windows 7 Service Pack 1, Windows 8, Windows 8. Warning: This site requires the use of scripts, which your browser does not currently allow. See how to enable scripts. Select Language:. Choose the download you want. Download Summary:. Total Size: 0. Back Next. Microsoft recommends you install a download manager. Microsoft Download Manager. Manage all your internet downloads with this easy-to-use manager.
It features a simple interface with many customizable options:. Download multiple files at one time Download large files quickly and reliably Suspend active downloads and resume downloads that have failed. Yes, install Microsoft Download Manager recommended No, thanks. What happens if I don’t install a download manager?
Why should I install the Microsoft Download Manager? In this case, you will have to download the files individually. You would have the opportunity to download individual files on the “Thank you for downloading” page after completing your download. Files larger than 1 GB may take much longer to download and might not download correctly.
You might not be able to pause the active downloads or resume downloads that have failed. For an updated version of these redistributable packages, see KB Details Note: There are multiple files available for this download. Once you click on the “Download” button, you will be prompted to select the files you need. File Name:.
Date Published:. File Size:. System Requirements Supported Operating System. Install Instructions To download all files and then install: On this page, choose the Download button. Select the.
To install now, choose the Run button. To install later, choose the Save button. The computer does not have to be connected to the Internet. Additional Information For important information about this release, see the Visual Studio Readme.
Follow Microsoft Facebook Twitter.
In this series we primarily use Komodo as our IDE for practice. Komodo is an opensource project free from Active-State , along with Tcl it supports several other languages. However, we use this for Tcl only in this course. The Latest version Komodo-v Hence will be using Komodo-v11 for this course, which can be downloaded from here. Installation of Komodo-v11 is straight forward, no complex steps involved in the process list of steps provided below. However, you may need to register when you open the IDE for the first time, hence register yourself here and keep your user-id and password in hand.
To test, whether the IDE is working properly or not. Create a file and paste the following code in it. Thats simple it is. If you face any difficulties while installation, first refer here for potential solution. If you did not found any solution, please comment in the comment section, I will try to resolve the issue.
Tcl has an inbuilt compiler called tclsh. It also has another executable tclsh Komodo uses the same executable to run the. We can execute the same without Komodo IDE. However, Komodo provides additional features such as variable type viewer, debugging using break points etc. Following are some online tools I Prefer most to compile and cross verify the.
Note – If any example is not working or any links are not working, please comment I will update with appropriate ones…. Subscribe and download our best stuff for free on Civil Engineering Essentials and several other topics. Written by Vijay Kumar Polimeru on February 20, For More Updates Subscribe and download our best stuff for free on Civil Engineering Essentials and several other topics Subscribe
It’s just that my first reaction was to feel a bit depressed about having a more limited distro, because of the potential for a fat batteries-included distro to get folks interested in Tcl.
I am sure there is some consensus that could be made. I would go for: tcllib tklib sqlite tkcon anything needed for starkits That would be my “bare minimum”.
I’ve answered this in some other thread recently, but to reiterate there are a couple key issues. Too many redundant packages that did the same thing.
This leads to maintenance headaches for us and choice headaches for users. The teapot didn’t exist for 8.
People need to get used to it, and you could call this the cold shower approach. The BI isn’t being dropped, it is being put on a diet. My bad. I have started using it so the cold shower worked. For myself, it works and works well. And I think AS have done a good job of it, sorting out a lot of devilishly nasty issues. The metadata lack of caching problem is the only big issue that’s irritated me so far. OK, it could do with a GUI front-end.
Someone’s weekend project perhaps? With RH, I’d say the “cold shower” worked for me. If it catches on, maybe it will be the calling card for Tcl that I can use to interest other developers. Note also that Andreas is currently on vacation, so nothing can be dealt with immediately. Now is the best time to reflect on what is there and consider what you really really want in a BI. What about simply making several differently-sized “battery packs”?
One of them would be “Everything” i. I don’t think I would push more than one ActiveTcl distro on Activestate. Everything else is brought down with teacup.
Forget why we are talking about all this? I think he is right Creating such distros is not very complicated, but making sure that they will always work and fit together in the long term My vote is also for one AS distro, including tcllib.
But, again, it would be really cool to have a [package require] that downloads missing packages automatically from a teapot repository network connection and correct setup assumed. Not distribs, just subsets of the teapot, at any given time, to be downloaded more efficiently than one-by-one by teacup. Tcllib is your choice. Others differ. I never use it.
I rather depend on extensions. Not two people will depend on the same set. That makes a strong case for a 8. Another argument that gets my sympathy is that during the 8. A full battery pack has tremendous pedagogic value. Um no. It isn’t full circle at least I don’t think so in the way you think. I think tcllib is the minimum to include and maybe 3 or 4 max more. Everything else should be gotten via teacup.
With the most gracious possible nod to ActiveState for providing ActiveTcl, I have to say that announcing this distribution as 8. Like others, I have not followed all the betas carefully and only popped my head up when I noticed, at my supervisor’s prodding, that 8.
So I did. To be as constructive as I can, I think: 1 the web page descriptions should be repaired to describe what is being provided 2 installation and upgrade information must be provided 3 the installer should be fixed to indicate that installing on top of a current installation is ok – at least until it no longer is. Won’t keep me from using Tcl, but it will keep me from upgrading to 8. Right, I think that is a valid argument. When I started with Tcl, I did it the same way and I am sure that I would find out about more useful packages if I had a all-in-one distro of 8.
But then I would vote for a full batteries included distribution only – at least for the free download. There is also ActiveTcl Enterprise, and when I understand this concept right, it means that any customized distribution can be created on a paid basis. I tried to follow this thread, waited a while and thought about mailing or not I never realized the differences in the ActiveTcl 8. So perhabs I should shut my mouth and be happy. The only reason I take part now in this discussion is, that I’m not glad about the need to administrate now my tcl distribution by using teacup.
If I install ActiveTcl 8. And this is anoying for me. I was so glad, that I don’t have to Like I was glad, that SVN has its Tourtoise, so that there is no need to learn all the syntax and syntactical sugar of the svn commandline binaries. Perhabs I hate this commandline stuff, because I’m already a child of the Microsoft era, used to GUIs, used to have several ways to reach the same goals, to have the same functionality, no need remember all the console things.
I have to remember a lot and I’m even a bit of a sadomasist, because I work most of my time with VIM and all its key-bindings and commands to be typed. That is much easier for me, than to learn all the teacup things, too. It would have been nice to signal this fact. All good points. I started using the ActiveTcl distro because it was a “BI” release. I think maybe they just want to rethink what “BI” is to include. Or perhaps a standard script that downloads everything from the AS teapot, along with remembering the date it was last run.
I think that would solve many problems except the “our machines aren’t on the net” problem. Assuming I understand how the whole teapot thing works. A script that needs something from the teapot could first check if the remembered date is later than the date when the needed packages were added, and if so, skip pulling down what it needs. That is good but I think Martin was saying he didn’t want to use teacup but have a good standard “BI” version. Sorry to jump on the bandwagon, but I just wanted to echo Craig’s experiences with the ActiveTcl 8.
All five of his points are important, but points 4 and 5 are especially relevant. I also uninstalled ActivelTcl 8. I didn’t know about it until I installed 8. The tips on the Tcler’s wiki helped a lot — it’d be great if they were expanded and put up on teapot.
Additionally, it’d be nice if the installer prompted users to retrieve packages via teacup at installation. I don’t mean to sound negative. The ActiveTcl team has done great work and has made it easy for a newbie like me to get started with Tcl. Keep up the good work guys! Cheers, Edmond. This the place where the user can be informed of what is going to be installed and where.
Information on how to use teacup to reproduce a BI install could also be given for later reference. This would at least make it a one step install for people who want BI installs, although it may take longer and does require a network conection Derek Derek Philip wrote:. I like this idea AS folk, does this sound reasonable to you, and if so, how hard would it be to implement?
It assumes good internet access, but since the installer was also probably downloaded, maybe that can be assumed?? This may be “pie in the sky” but when you install XEmacs over the Internet you get to choose what packages you want it to install for you.
But as others have said, it’s easier for me to try using other packages if they are already there. If the extra packages are going to be available from ActiveState via teapot, presumably ActiveState is spending the time to build and QA them.
If this is happening anyway as packages are added or updated in the repository, could ActiveState just take a snapshot of as much as possible of the repository periodically eg. Please bear in mind that some of us have to install on machines that do not have internet access eg.
Make no assumptions that we are QA’ing these things. If they build, they are available. This really defeats the entire purpose of a repo, and I hope that the repo is just going to grow.
Nobody would want the entire contents of CPAN either. Yes, there is a fine balance to be met, somewhere between all extensions and none. Everybody was happy with ActiveState 8. If internet speed is growing and growing, storage space grows even faster, who minds about the size of the download package? In my opinion, Activestate 8. What is it nicer that telling someone? Go and download ActivestateTCL. You make an assumption here that “everybody” was happy with it. The maintainer aka ActiveState was not happy with it so now we wheel and deal.
We can still do that but with a little more thought given to what is to go into it. The kitchen sink is bad. Or is the assumption that other repos will pop up? Might be right, but who is to decide what is “in” and what is “out”?
Obviously AS did and not everybody is happy. This is where the problem starts. Up until 8. No need to worry that something might not work anymore – yes, i know, somewhat naive, but it did the trick all the time at least for me. The included modules might not be the latest versions, but they worked. Now things are different, quite some scripts need looking into.
It seems we are getting dumped into some CPAN-like hell – myriads of modules to choose from. There might be the code that i actually need, but, searching for it could take almost as much time as reinventing the wheel, with the risk of not finding anything of use.
I feel not too happy with the decision to remove stuff from the distribution. But for the time being, i will stick with 8. I believe that last sentence is it. There will be some sort of “BI” from Activestate and I am pretty sure Jeff is reading all of these kinds of posts. I am moving stuff now so that I can help find bugs and give input. I liked the 8. Best to be a part of the process in my opinion. I ask just to get an idea and bounce it against other suggestions about what to include.
Sometimes things change to improve and some other to become worse. Better than just adapting to change it is to try to influence this change to go in the best direction.
And, in an extreme situation, provide an alternative of course, not for this case as AS is making a very good work. I’ve tried the “on to of” several times over the past year thinking that AS would eventually get it to work, well it still doesn’t. I’ve tried this on both Windows and Linux and what happens is that the 8. Perhaps you could give a fuller explination of how to do an install of 8.
Tom K. An alternative to installing 8. As to the other issues, that is indeed peculiar. We have gone to some lengths to make this work, so I’m not sure why it doesn’t for you. They say “you can’t cure stupid” will “you can’t cure senility” eather. I was doing a package require on tcllib to check for access to the libraries, which of course isn’t a package any more. Sorry for the noise on this channel. Is ActiveTcl 8.
Georgios Petasis. Reply to author. Report message as abuse. Show original message. Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message.
Hi all, I just tried to upgrade to ActiveTcl 8. Robert Hicks. Jeff Hobbs. Alexandre Ferrieux. Alan Anderson. Bryan Oakley. Well, my opinion is that now that 8. Microsoft Download Manager. Manage all your internet downloads with this easy-to-use manager. It features a simple interface with many customizable options:.
Download multiple files at one time Download large files quickly and reliably Suspend active downloads and resume downloads that have failed. Yes, install Microsoft Download Manager recommended No, thanks. What happens if I don’t install a download manager? Why should I install the Microsoft Download Manager? In this case, you will have to download the files individually. You would have the opportunity to download individual files on the “Thank you for downloading” page after completing your download.
Files larger than 1 GB may take much longer to download and might not download correctly. You might not be able to pause the active downloads or resume downloads that have failed. For an updated version of these redistributable packages, see KB Details Note: There are multiple files available for this download. Once you click on the “Download” button, you will be prompted to select the files you need. File Name:. Date Published:. File Size:. System Requirements Supported Operating System.
Install Instructions To download all files and then install: On this page, choose the Download button. Select the. To install now, choose the Run button.
To install later, choose the Save button.
Все встало на свои места. – Ну конечно, – сказала она, все еще не в силах поверить в произошедшее. – Он хотел, чтобы вы восстановили его доброе имя. – Нет, – хмуро сказал Стратмор. – Танкадо потребовал «ТРАНСТЕКСТ».
Total Size: 0. Back Next. Microsoft recommends you install a download manager. Microsoft Download Manager. Manage all your internet downloads with this easy-to-use manager. It features a simple interface with many customizable options:.
Download multiple files at one time Download large files quickly and reliably Suspend active downloads and resume downloads that have failed. Yes, install Microsoft Download Manager recommended No, thanks.
What happens if I don’t install a download manager? Why should I install the Microsoft Download Manager? In this case, you will have to download the files individually.
You would have the opportunity to download individual files on the “Thank you for downloading” page after completing your download. Files larger than 1 GB may take much longer to download and might not download correctly. You might not be able to pause the active downloads or resume downloads that have failed. For an updated version of these redistributable packages, see KB Details Note: There are multiple files available for this download.
Once you click on the “Download” button, you will be prompted to select the files you need. File Name:. Date Published:. File Size:. System Requirements Supported Operating System. Install Instructions To download all files and then install: On this page, choose the Download button. Branches Tags. Could not load branches. Could not load tags. Latest commit. Git stats 15 commits. Failed to load latest commit information. Feb 15, Initial import of the code I developed back in Nothing has been….
Jul 14, Updated the readme with some better text, added the Gow license, impr…. Jul 20, Apr 29, Adding default Bash configuration to set user’s home directory, and l…. Apr 26, Added PuTTy 0. Remove repeated “of”. Aug 11, View code.