Government Security
Network Security Resources

Jump to content

Photo

A Boilerplate Go Program File

- - - - - javascript tools sql
  • Please log in to reply
No replies to this topic

#1 Stephen

Stephen

    Commander In Chief

  • GSO Management
  • 1,806 posts

Posted 01 August 2010 - 11:30 PM


Creating a quick program in go is very easy, you could almost say it’s easier then adding a javascript function to a page.This makes it a great language to quickly create a throwaway tool to do a certain task. Just like a SQL script to extract data or like the old .prg’s that were used with dBase.While you can easily start from a blank document and add the standard elements that you need to include, I’ve created a simple “jumping off” point that I’m using for all of my Go program’s.Albeit 9 lines long, here it is anyway.


package main

import (
	"fmt"
)

func main() {
	fmt.Printf("Hello")
}

Posted Image





Also tagged with one or more of these keywords: javascript, tools, sql