aka 0.5.1 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
data/LICENSE.txt CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2013 YOUR NAME
1
+ Copyright (c) 2013 Nate Dickson
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
4
 
data/README.md CHANGED
@@ -2,23 +2,31 @@
2
2
 
3
3
  AKA is an alias manager. keep tabs on all of your alias'ed commands, shortcuts, and more without hand-editing dot files.
4
4
 
5
- ## Installation
5
+ ## What?
6
+
7
+ If you work on the command line a lot you know there are commands that get really tedious to type out over and over again. for decades command line pros have been adding aliases to their shell to alleviate this problem. Simply add a line like `alias proj="cd /path/to/current/project"` to your `.profile` file and the next time you log in you can do this:
8
+
9
+ $ proj
10
+ instead of this:
6
11
 
7
- For now (meaning, until I get this into [RubyGems]) use these steps
12
+ $ cd /path/to/current/project
13
+ And you've just saved yourself 22 characters' worth of typing.
8
14
 
9
- $ cd /path/to/aka
15
+ But what if you really don't want to edit your profile files every time you want to add or remove one of these aliases? Well, you can just move all the alias definitions into a file named, say `~./alias` and then you just add one line to `.profile`:
10
16
 
11
- Then execute:
17
+ source ~/.alias
12
18
 
13
- $ bundle
19
+ And now you can just edit the `.alias` file.
14
20
 
15
- Or install it yourself as:
21
+ Or you can use `aka`.
22
+
23
+ ## Installation
16
24
 
17
- $ gem install /path/to/aka
25
+ $ gem install aka
18
26
 
19
27
  ## Usage
20
28
 
21
- 1. add the line `source ~/.alias` to your `.bash_profile` or `.profile` or `.bashrc`… basically whatever profile file you use on your system.
29
+ 1. add the line `source ~/.alias` to your `.bash_profile` or `.profile` or `.zshrc`… basically whatever profile file you use on your system.
22
30
  2. run `aka -a hi "echo Hi There!"`
23
31
  3. type `source ~/.alias` to reload the aliases in your current session (or restart your session)
24
32
  4. type `hi`
@@ -29,5 +37,20 @@ Or install it yourself as:
29
37
 
30
38
  Pull requests and issues are very welcome. If you have time, please include a solution or a test with any issues you submit.
31
39
 
40
+ ##Acknowledgements
41
+
42
+ Many, many thanks go to [David Copeland] for the [Methadone] framework that made this app possible and [his book][awesomeApps] which made it easy.
43
+
44
+ ## Roadmap
45
+
46
+ I really like this app, but I've got other things I want to work on. But there are a few features I'm still planning to add:
47
+
48
+ 1. Support for a config file that will let you use a file other than `~/.alias` for your aliases
49
+ 1. Grouping aliases
50
+ 1. Aliases sorted alphabetically by default.
51
+
32
52
 
33
- [RubyGems]:https://rubygems.org/
53
+ [David Copeland]:http://www.naildrivin5.com/
54
+ [Methadone]: http://davetron5000.github.com/methadone/
55
+ [RubyGems]:https://rubygems.org/
56
+ [awesomeApps]:http://www.awesomecommandlineapps.com/
data/README.rdoc CHANGED
@@ -13,7 +13,7 @@ Add <code>source ~/.alias</code> to your profile.
13
13
 
14
14
  == Links
15
15
 
16
- * {https://github.com/PogiNate/A.K.A.}[LINK TO GITHUB]
16
+ * {http://poginate.github.com/A.K.A./}[LINK TO GITHUB]
17
17
  * RDoc[LINK TO RDOC.INFO]
18
18
 
19
19
  == Install
@@ -22,7 +22,7 @@ Add <code>source ~/.alias</code> to your profile.
22
22
 
23
23
  == Examples
24
24
 
25
- * To add a new alias enter <code>aka -n hi "echo "hi there!"</code>
25
+ * To add a new alias enter <code>aka -a hi "echo "hi there!"</code>
26
26
  * enter <code>aka -h</code> to see the other available commands.
27
27
 
28
28
  == Contributing
data/aka-0.5.1.gem ADDED
Binary file
data/lib/aka/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Aka
2
- VERSION = "0.5.1"
2
+ VERSION = "0.5.2"
3
3
  end
data/lib/aka.rb CHANGED
@@ -10,6 +10,9 @@ module Aka
10
10
  @aliasPattern = /alias (\S+)="(.+)"/
11
11
  @aliases = {}
12
12
  @fileName = "#{ENV["HOME"]}/.alias"
13
+ if !File.exists? @fileName
14
+ FileUtils.touch @fileName
15
+ end
13
16
  debug ("made it to the class. filenName is #{@fileName}, aliasPattern is #{@aliasPattern}.")
14
17
  #Open the alias list
15
18
  File.foreach(@fileName) do |line|
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aka
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-02-07 00:00:00.000000000 Z
12
+ date: 2013-02-08 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rdoc
@@ -90,6 +90,7 @@ files:
90
90
  - README.md
91
91
  - README.rdoc
92
92
  - Rakefile
93
+ - aka-0.5.1.gem
93
94
  - aka.gemspec
94
95
  - bin/aka
95
96
  - features/add.feature