Skip to content

Commit

Permalink
Ready for test-release (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
jpmartha committed Apr 29, 2016
1 parent 5de3c91 commit ae3b9e8
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,12 @@ Maybe it is easily to write a shell (e.g. Bash), _but this is exactly **"try! Sw

<br />

## Installing (Coming soon)
## Installing

Please download the `tryswiftdev.pkg` in the [Releases](https://github.com/tryswift/tryswiftdev/releases) and install it.

_**This is a test release. It has not gone through the testing.**_

By default, get `tryswiftdev` into the `/usr/local/bin/` directory.

You can verify your installation by typing `tryswiftdev` in a Terminal.app.
Expand All @@ -38,9 +40,9 @@ $ tryswiftdev

```
-d [--duplicate-readme] Duplicate an existing README.md.
Do not overwrite an existing file.
Do not overwrite an existing file.
-r [--replace-readme] Replace strings in a README.md
located in the current directory.
located in the current directory.
-h [--help] Display available options.
```

Expand All @@ -62,7 +64,7 @@ HomeDirectory
### Duplicating a README.md

```bash
$ tryswiftdev -d ../Pokemon ../DragonBall
$ tryswiftdev -d ./Pokemon ./DragonBall
```

```
Expand Down
4 changes: 2 additions & 2 deletions Sources/Option.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ enum Options: String, CustomStringConvertible {
switch self {
case .DuplicateReadme:
return "Duplicate an existing README.md."
+ "\n Do not overwrite an existing file."
+ "\n Do not overwrite an existing file."
case .ReplaceStringsInReadme:
return "Replace strings in a README.md"
+ "\n located in the current directory."
+ "\n located in the current directory."
case .Usage:
return "Display available options."
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Readme.swift → Sources/Readmemd.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ let readmeFileName = "README.md"

/// Do not overwrite an existing file.
func duplicateExistingReadme(existingReadmeDirctoryPath sourcePath: String, newReadmeDirectoryPath targetPath: String) {
excuteCommand(argments: ["cp", "-n", sourcePath + "/" + readmeFileName, targetPath])
excuteCommand(argments: ["cp", "-n", "\(sourcePath)/\(readmeFileName)", targetPath])
}

func replaceStringsInReadme(source: String, target: String) {
Expand Down
2 changes: 1 addition & 1 deletion Sources/Usage.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ func usage() {
print(" $ tryswiftdev [option <value> ...]")
print("")
print("EXAMPLE:")
print(" $ tryswiftdev -d ../Pokemon ../DragonBall")
print(" $ tryswiftdev -d ./Pokemon ./DragonBall")
print(" $ tryswiftdev -r Pokemon DragonBall")
print("")
print("_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/")
Expand Down

0 comments on commit ae3b9e8

Please sign in to comment.