colorls 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 65bb6af39e0cef4207180fd355951ed8af588467
4
- data.tar.gz: 9ddd72d0fee92a585bd70c5a3127d6e7e9400be1
3
+ metadata.gz: ee46843601bfbf8dcda5a4cf90aec6208053193b
4
+ data.tar.gz: efb20ac3426e5a0c4ebb0104ca1902559e41cda9
5
5
  SHA512:
6
- metadata.gz: 9d6bc7bb007ce73ac38758bcccd772047d1322a749fbe1b994b9899ec6cb4c0e7d2a915731e93c0023593fe980580f6d144a679954084a81a3b33b4e6c6ef225
7
- data.tar.gz: 532d8723491a7b1053e5cb659f85d9b1da8c898779aff2c25ea307b1010178e9fc7dd96893f1c9aa235d1715b580089dbdac1ac9536aab37b554a59b0c131f41
6
+ metadata.gz: 62cded3301273f822645fd013b63b71e6350d0599f7f4f521b7bfeb0c57fc6a292c698163d832f00949b9f91066889e810cb1fe7a0db85cce223e2871aca7331
7
+ data.tar.gz: 4e79f2693b6272e4bd86f7c7190b5e226674d1126736f4e35eeafd55e48800cb505e28b8657d44339b6e44465f51d7541bdadc6fdf437f73d405f1db3f6f2342
@@ -11,13 +11,14 @@ script:
11
11
  - bundle exec rubocop
12
12
  - bundle exec rspec
13
13
  - rake install
14
- - lc
15
- - lc -d
16
- - lc -f
17
- - lc -sd
18
- - lc -sf
19
- - lc -1
20
- - lc -r
14
+ - colorls
15
+ - colorls -a
16
+ - colorls -d
17
+ - colorls -f
18
+ - colorls -sd
19
+ - colorls -sf
20
+ - colorls -1
21
+ - colorls -r
21
22
 
22
23
  install:
23
24
  - gem install bundler
@@ -25,10 +25,10 @@ Please proceed with a Pull Request only after you're assigned. It'd be sad if yo
25
25
  - adding better icons to [YAML files](lib/yaml/)
26
26
  - adding more flag options to the ruby gem.
27
27
 
28
- 3. (Optional) To test whether `lc` is working properly, do
28
+ 3. (Optional) To test whether `colorls` executable is working properly, do
29
29
  ```sh
30
30
  rake install
31
- lc # start using lc
31
+ colorls # start using colorls
32
32
  ```
33
33
 
34
34
  4. (Required for YAML file changes) These are the specifications for the YAML files -
data/README.md CHANGED
@@ -12,8 +12,9 @@ A Ruby script that colorizes the `ls` output with color and icons. Here are the
12
12
  # Table of contents
13
13
 
14
14
  - [Usage](#usage)
15
- - [Installatation](#installation)
16
- - [Optional configurations](#optional-configurations)
15
+ - [Installation](#installation)
16
+ - [Recommended configurations](#recommended-configurations)
17
+ - [Updating](#updating)
17
18
  - [Uninstallation](#uninstallation)
18
19
  - [Contributing](#contributing)
19
20
  - [License](#license)
@@ -54,7 +55,10 @@ A Ruby script that colorizes the `ls` output with color and icons. Here are the
54
55
  [(Back to top)](#table-of-contents)
55
56
 
56
57
  1. Install Ruby (prefably, version > 2.1)
57
- 2. Install the patched fonts of powerline nerd-font and/or font-awesome.
58
+ 2. Install the patched fonts of powerline nerd-font and/or font-awesome. Have a look at [nerdfont's README](https://github.com/ryanoasis/nerd-fonts/blob/master/readme.md) for more installation instructions.
59
+
60
+ *Note for `iTerm2` users - Please enable the nerd-font at iTerm2 > Preferences > Profiles > Text > Non-Ascii font > Knack Regular Nerd Font Complete.*
61
+
58
62
  3. Install the [colorls](https://rubygems.org/gems/colorls/) ruby gem with `gem install colorls`
59
63
 
60
64
  *Note for `rbenv` users - In case of load error when using `lc`, please try the below patch.*
@@ -64,15 +68,15 @@ A Ruby script that colorizes the `ls` output with color and icons. Here are the
64
68
  rehash
65
69
  ```
66
70
 
67
- 4. Start using `lc` :tada:
71
+ 4. Start using `colorls` :tada:
68
72
 
69
- # Optional configurations
73
+ # Recommended configurations
70
74
 
71
75
  [(Back to top)](#table-of-contents)
72
76
 
73
- 1. To add some flag options by default, add this to your shell configuration file (`~/.bashrc`, `~/.zshrc` or `~/.fishrc`) :
77
+ 1. To add some short command (say, `lc`) with some flag options (say, `-r`)b y default, add this to your shell configuration file (`~/.bashrc`, `~/.zshrc` or `~/.fishrc`) :
74
78
  ```sh
75
- alias lc='lc -r'
79
+ alias lc='colorls -r'
76
80
  ```
77
81
  2. For changing the icon(s) to other unicode icons of choice (select icons from [here](https://nerdfonts.com/)), change the YAML files in a text editor of your choice (say, `subl`)
78
82
 
@@ -80,7 +84,15 @@ A Ruby script that colorizes the `ls` output with color and icons. Here are the
80
84
  subl $(gem which colorls)/../yaml/
81
85
  ```
82
86
 
83
- _NOTE: If you're using iTerm2 on Mac, you may have to enable the nerd-font at iTerm2 > Preferences > Profiles > Text > Non-Ascii font > Knack Regular Nerd Font Complete_
87
+ # Updating
88
+
89
+ [(Back to top)](#table-of-contents)
90
+
91
+ Want to update to the latest version of `colorls`?
92
+
93
+ ```sh
94
+ gem update colorls
95
+ ```
84
96
 
85
97
  # Uninstallation
86
98
 
@@ -1,8 +1,10 @@
1
1
  module ColorLS
2
2
  class Core
3
- def initialize(input=nil, report: false, sort: false, show: false, one_per_line: false)
3
+ def initialize(input=nil, all: false, report: false, sort: false, show: false,
4
+ one_per_line: false)
4
5
  @input = input || Dir.pwd
5
6
  @count = {folders: 0, recognized_files: 0, unrecognized_files: 0}
7
+ @all = all
6
8
  @report = report
7
9
  @sort = sort
8
10
  @show = show
@@ -29,6 +31,7 @@ module ColorLS
29
31
  def init_contents
30
32
  @contents = Dir.entries(@input) - %w[. ..]
31
33
 
34
+ @contents.keep_if { |x| !x.start_with? '.' } unless @all
32
35
  filter_contents if @show
33
36
  sort_contents if @sort
34
37
 
@@ -5,6 +5,7 @@ module ColorLS
5
5
  @opts = {
6
6
  show: fetch_show_opts,
7
7
  sort: fetch_sort_opts,
8
+ all: flag_given?(%w[-a --all]),
8
9
  report: flag_given?(%w[-r --report]),
9
10
  one_per_line: flag_given?(%w[-1])
10
11
  }
@@ -1,3 +1,3 @@
1
1
  module ColorLS
2
- VERSION = '0.1.3'.freeze
2
+ VERSION = '0.1.4'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: colorls
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Athitya Kumar