Autolycus Language Specifications

Input File Format

Commands

Variables

Example Scripts

 


 

Input File Format (back to top)

  • Text file with .ATL extension
  • Commands are case-insensitive
  • Literal text values used as parameters to commands do not need quotes around them unless they contain a comma
  • Commands are separated by being on separate lines or by semicolon
  • The double forward-slash is the symbol for comments

Commands (back to top)

  • BlockInput
  • UnblockInput
  • SetScreenRes width, height
  • RestoreScreenRes
  • Click x, y, button
    • button should be "left", "right", or "middle" (with or without the quotes)
  • SendKeys keys
  • Launch FullFilePath, Context
    • FullFilePath should have drive letter, directory path, and filename with extension.
    • Context should be "regular" or "admin"
  • SetFocusByTitle Title
    • Title for this command and next three is the process name. IE for Notepad it is "notepad"
  • MaximizeByTitle Title
  • MinimizeByTitle Title
  • KillProcessNamed Title
  • OpenWebBrowserTo Address
    • Address is URI/URL. Example: http://www.google.com/ or http://mysite.com/ipupdate.php?newip=$wanipaddress$ (where $wanipaddress is an autolycus variable for your external ip address)
  • Wait Milliseconds
  • LoopStart
  • LoopEnd
  • LoopXTimes Times
  • LoopXTimesEnd
  • ForEachFileIn FolderPath
    • FolderPath example: "C:\Folder\Subfolder"
  • NextFile
  • ForEachLineIn FullFilePath
    • FullFilePath example: "C:\Folder\Subfolder\list.txt"
  • NextLine
  • FtpUpload LocalFilePath, RemoteFilePath, Username, Password
    • LocalFilePath example: "C:\Folder\Subfolder\filetoupload.zip"
    • RemoteFilePath example: "ftp://ftp.mysite.com/filenameondestination.zip"
  • FtpDownload RemoteFilePath, LocalFilePath, Username, Password
  • Zip FolderToZip OutputFile
    • FolderToZip example: "C:\Folder\Subfolder"
    • OutputFile example: "C:\Folder\SubfolderZipped.zip"
  • Unzip ZipFile ExtractPath
  • MoveFile SourceFile, DestinationFile
  • CopyFile SourceFile, DestinationFile
  • DeleteFile Filename

Variables (back to top)

Available for use as or in parameters sent to any command that takes parameters:

  • $date$
  • $time$
  • $currentdirectory$
  • $pcname$
  • $wanipaddress$
  • $lanipaddress$
  • $foreachfilename$ (while in foreachfilein loop)
  • $foreachlinetext$ (while in foreachlinein loop)
  • $carriagereturn$
  • $linefeed$
  • $newline$

Example Scripts (back to top)

Script 1: Block/unblock input, Set/restore screen resolution, Launch and control notepad, Send keystrokes and clicks, and Loop through files in a directory:

blockinput // disable mouse and keyboard input

setscreenres 800, 600
wait 4000

launch "c:\windows\notepad.exe", regular, "" // specify regular to run normally or admin to run as administrator account
wait 2000

minimizebytitle "notepad"; wait 2000

maximizebytitle "notepad"; wait 2000

setfocusbytitle "notepad"; wait 2000

sendkeys "testing 1 2 3 testing testing 1 2 3 4 5 6 7 8"; wait 2000

click 100,100,right // pull up right click context menu; wait 2000

click 140,107,left // click "Undo"; wait 2000

sendkeys $currentdirectory$
sendkeys $newline$
wait 2000

foreachfilein $currentdirectory$

    sendkeys $foreachfilename$
    sendkeys $carriagereturn$
    wait 500

nextfile

killprocessnamed "notepad"
wait 2000

restorescreenres
wait 2000

unblockinput