by alexander white ©
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --To Create the database & add user to that | |
| CREATE DATABASE <dbname>; | |
| CREATE USER <username>; | |
| \password <username> | |
| GRANT ALL PRIVILEGES ON DATABASE <dbname> TO <username>; | |
| ALTER DATABASE <dbname> OWNER TO <username>; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| bunzip2 <filename>.tbz | |
| pg_restore --clean -U <db_user_name> -d <database_name> -F tar -v <filename_tar_file>.tar |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Routes | |
| # This file defines all application routes (Higher priority routes first) | |
| # ~~~~ | |
| module:testrunner | |
| GET / App.Index | |
| # Ignore favicon requests | |
| GET /favicon.ico 404 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 17:34 $ go build | |
| watcher.go:4:2: cannot find package "gopkg.in/fsnotify.v1" in any of: | |
| /usr/local/Cellar/go/1.3.1/libexec/src/pkg/gopkg.in/fsnotify.v1 (from $GOROOT) | |
| /Users/kishore/gothings/src/gopkg.in/fsnotify.v1 (from $GOPATH) | |
| ~/gothings/src/github.com/revel/revel [master|✚ 2] | |
| 17:34 $ go install | |
| watcher.go:4:2: cannot find package "gopkg.in/fsnotify.v1" in any of: | |
| /usr/local/Cellar/go/1.3.1/libexec/src/pkg/gopkg.in/fsnotify.v1 (from $GOROOT) | |
| /Users/kishore/gothings/src/gopkg.in/fsnotify.v1 (from $GOPATH) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "encoding/xml" | |
| "fmt" | |
| ) | |
| type Embed struct { | |
| XMLName xml.Name `xml:"Embed"` | |
| Body string `xml:"Body,omitempty"` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| "io/ioutil" | |
| "log" | |
| "net/http" | |
| ) | |
| var INDEX_HTML []byte |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| SELECT 'ALTER FUNCTION '||p.proname || '('||oidvectortypes(p.proargtypes)||') OWNER TO "'||current_catalog||'";' | |
| FROM pg_catalog.pg_proc p | |
| LEFT JOIN pg_catalog.pg_namespace n ON n.oid = p.pronamespace | |
| WHERE pg_catalog.pg_function_is_visible(p.oid) | |
| AND n.nspname <> 'pg_catalog' | |
| AND n.nspname <> 'information_schema' | |
| AND p.probin IS NULL; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ### The below commands are used to change all the Datasources from one to another for JasperSoft Server configuations during export import process. | |
| rm -rf /tmp/test_export | |
| mkdir /tmp/test_export | |
| cp export.zip /tmp/test_export | |
| cd /tmp/test_export | |
| unzip export.zip | |
| find ./ -type f | xargs sed -i 's/delt_cp_api/multi_contractport_api/g' | |
| zip -r -x export.zip new_export.zip * | |
| cd - |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Sub ChangeWorkSheetName() | |
| 'Updateby20140624 | |
| Dim Rng As Range | |
| Dim WorkRng As Range | |
| On Error Resume Next | |
| xTitleId = "KutoolsforExcel" | |
| newName = Application.InputBox("Name", xTitleId, "", Type:=2) | |
| For i = 1 To Application.Sheets.Count | |
| Application.Sheets(i).Name = newName & i | |
| Next |
OlderNewer