Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

IronAHK - .NET port of AutoHotkey for Windows, Linux, Mac...


  • This topic is locked This topic is locked
48 replies to this topic
polyethene
  • Members
  • 5519 posts
  • Last active: May 17 2015 06:39 AM
  • Joined: 26 Oct 2012

would it be possible to provide some steps on how would I compile this in linux

The Mono website has some good articles on the CSharp Compiler and Introduction to developing with Mono. It doesn't matter where you compile .NET applications as the same files should run on all platforms (like java). I'm using VS08 but you can easily switch to MonoDevelop, Eclipse or write a bash/batch script for the command line.

autohotkey.com/net Site Manager

 

Contact me by email (polyethene at autohotkey.net) or message tidbit


bits
  • Members
  • 10 posts
  • Last active: Dec 08 2010 01:13 AM
  • Joined: 17 Nov 2006
Thanks for the reply. That should give me a start off.

I am compiling mono compiler right now... Hoping to get things done as expected.

btw, I would like to know if you or anyone else have successfully compiled and ran it successfully in linux environment?

regards,
Shobhit

IsNull
  • Moderators
  • 990 posts
  • Last active: May 15 2014 11:56 AM
  • Joined: 10 May 2007
amzing project! :)

But it looks like this link is down:
<!-- m -->http://ironahk.googl... ... HK_bin.zip<!-- m --> (binary build)

returns 404 file not found...


regards
IsNull

polyethene
  • Members
  • 5519 posts
  • Last active: May 17 2015 06:39 AM
  • Joined: 26 Oct 2012
I removed the binary for now because the parser is incomplete and unsafe to run. The DLL is available at <!-- m -->http://ironahk.googl... ... .Rusty.dll<!-- m -->

autohotkey.com/net Site Manager

 

Contact me by email (polyethene at autohotkey.net) or message tidbit


polyethene
  • Members
  • 5519 posts
  • Last active: May 17 2015 06:39 AM
  • Joined: 26 Oct 2012
The parser is up and mostly works! For more information visit the link in my previous post to the message on Google Groups.

For Linux

Building is very easy with the Makefile. You will need Mono 2.0+ and a Subversion client to get the source code:

$ mkdir IronAHK && cd IronAHK
$ svn co http://ironahk.googlecode.com/svn/trunk/
$ cd trunk
$ make
The standard flags, CC and CFLAGS can be used if your gmcs is not in $PATH or to change compiler settings. To run call mono iak.exe making sure you're in the bin folder first.

For Windows

You will need .NET 2.0 which is installed by default on Vista and XP SP2+. Download TortoiseSVN and VS08. Checkout the source code and open the solution with Visual Studio, press F6 to build.

For non-developers

An installer with newb-friendly tools and documentation will (hopefully) be provided with the v1 release.

autohotkey.com/net Site Manager

 

Contact me by email (polyethene at autohotkey.net) or message tidbit


ElliottB
  • Members
  • 8 posts
  • Last active: Nov 25 2008 06:09 AM
  • Joined: 01 Nov 2008
When you reach a stable level, I'll look into porting my basic applications. I think you should look into making 'ike' into more of a platform for rapid prototyping software than just a port of the automating nature of Autohotkey. I've always enjoyed EMCAscript, and I'd prefer to write software in it than C or C++.

polyethene
  • Members
  • 5519 posts
  • Last active: May 17 2015 06:39 AM
  • Joined: 26 Oct 2012
Over the years we've seen AutoHotkey being used for much more than macros and hotkeys. There is COM, "lowlevel" and extensive use of DllCalls everywhere because the current command set is so limited for the Windows developer. IronAHK was designed with this in mind and although the focus is cross-platform automation, the platform is open to all other aspects of scripting with APIs planned for database integration, sockets and much more.
I'm also a fan of EcmaScript. It is something all C#, Java, JavaScript and ActionScript programmers will instantly recognize. Writing a conversion utility for .ahk scripts to this syntax is a high priority task but will probably come after a v1 release. Thank you for your interest.

autohotkey.com/net Site Manager

 

Contact me by email (polyethene at autohotkey.net) or message tidbit


IsNull
  • Moderators
  • 990 posts
  • Last active: May 15 2014 11:56 AM
  • Joined: 10 May 2007
Dear Titan,

I'm glad to see progress in this Project. I would love to write Applications for Linux with AHK. I'm curently installing TortoiseSVN and will try it :)

The parser is up and mostly works!

SOunds good, but u have marked the status from the parser as 35%. Do you only have forgotten to update this value?


Thanks for your hard work!
regards
IsNull

twhyman
  • Members
  • 348 posts
  • Last active: Sep 17 2014 01:55 AM
  • Joined: 07 Dec 2005
Hi,

Will IronAHK be able to behave like a console script?
I mean see the output in CMD.exe for instance?

Thanks,
Twhyman
(\__/) This is Bunny.
(='.'=) Cut, copy, and paste bunny onto your sig.
(")_(") Help Bunny gain World Domination.

polyethene
  • Members
  • 5519 posts
  • Last active: May 17 2015 06:39 AM
  • Joined: 26 Oct 2012

SOunds good, but u have marked the status from the parser as 35%. Do you only have forgotten to update this value?

The information there was outdated, the parser is now 100% complete. The current task is writing an AutoHotkey v1 compatibility layer which is still in the early stages. Feedback from IRC indicated that ECMAScript syntax isn't as popular as I had expected among ahk users, so this has the highest priority. Trying to convert Chris' C++ version of script_expression.cpp is near impossible because it is written very poorly (unreadable and unmodular spaghetti code), supposedly for better performance. This means I have to study his parser and write a C# version from scratch.

Will IronAHK be able to behave like a console script?

Yes there will be functions for writing to stdout, stderr and reading stdin. Common needs for this would be CGI for HTTP and of course command line scripts (none of my Linux servers have a desktop environment).

autohotkey.com/net Site Manager

 

Contact me by email (polyethene at autohotkey.net) or message tidbit


snaggy
  • Guests
  • Last active:
  • Joined: --
Let's see if i understand this well...
I could with this script my OS X as I used to in windows? Send mouse clicks, remap keyboard, check which windows is open and what its title is... even if it's written in cocoa and not WinForms/GTk# ??

If so.. well.. it's fantastic !

Bye the way, if you're writing this in Mono, I could be able to access its commands with C#, and wouldn't need to use AHK Syntax at all, right?, combining the power of dotnet with the ease of use of ahk..

polyethene
  • Members
  • 5519 posts
  • Last active: May 17 2015 06:39 AM
  • Joined: 26 Oct 2012
I haven't looked into Cocoa# much recently but last time I checked the API was unstable or still incomplete. It should be straightforward to support but it'll have to happen at a later date. I personally do not have a Mac so I'll need someone to help me debug etc.

The Makefile creates IronAHK.Rusty.dll which is the core library of commands and functions. You can use it independently in any .NET/Mono application. More details soon.

autohotkey.com/net Site Manager

 

Contact me by email (polyethene at autohotkey.net) or message tidbit


moro
  • Guests
  • Last active:
  • Joined: --
Could i get small example how i use it?

Cause for example this code does nothing:

Rusty.Script script = new Script();
script.SetTitleMatchMode("2");
script.WinActivate("Mozilla Firefox", String.Empty, String.Empty, String.Empty);
Console.ReadLine();
script.MouseMove(350,350, 60, true);
Console.ReadLine();

what is wrong? I tried to compile with flag "Allow unsafe code" and it is the same.

Additional info:
Windows 2008 64k
Visual Studio 2008
Framework 3.5

moro
  • Guests
  • Last active:
  • Joined: --
Ok found solution setting platform target( in vs ) x86 - and it runs. If i leave it with setting "any cpu" it runs only on 32-bit machines. Still don`t know why( looking into it ) but it works.

jeffrey296
  • Members
  • 8 posts
  • Last active: Dec 22 2008 10:57 PM
  • Joined: 18 Jul 2008
So I understand the necessity for this project (being a subscriber to a previous forum trying to get this started), but what are the features (other than smaller file size) that make it better in Windows? Is the .NET framework the only change (projected or current)?

Also, I know someone who has a Mac who would be happy to test any pre-release versions you need to test, just pm me or post it on this forum (with detailed instructions).

Congrats on the project, I'm incredibly happy to see this thing going (a linux version has been desperately needed).
Jeff