custom_update_tags 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/bin/update_tags +51 -0
  3. metadata +103 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 32f053aa25f5ddc1515844fd8ce32e18614fb98f8d0b01d310863df62bb484e2
4
+ data.tar.gz: 3c2a39f341501ee10d38b4ffd7fe123bf6df34081603dde3dc6e69d0fe506fa5
5
+ SHA512:
6
+ metadata.gz: 53b8618e1fcee1d7c497495f6b22b53f219d61e2f9f9776f4f0c6af59e393efcc37d07e3a72d7b4dd587d5a4567694b1f95ae8197cd55fa3f014dbc994192842
7
+ data.tar.gz: 2d0a735231be567a84fba8a57b195cb9dfbac0cf11d12992d44c2a8ace3275a318776c04b2dd25dda64aa6680cde0de18edae8d5716cfb577264a4741b08d0f9
data/bin/update_tags ADDED
@@ -0,0 +1,51 @@
1
+ #!/usr/bin/ruby
2
+
3
+ require "update_tags"
4
+ require "thor"
5
+ require "filewatcher"
6
+
7
+ # update_tags now
8
+ # update_tags now --at tag --template _includes/tag_index_page.md
9
+ #
10
+ # update_tags continuously
11
+ # update_tags continuously --at tag --template _includes/tag_index_page.md
12
+
13
+ class UpdateTagsCli < Thor
14
+ DEFAULT_TAG_DIRECTORY = "tag"
15
+ DEFAULT_PATH_TO_TAG_INDEX_PAGE_TEMPLATE = "_includes/tag_index_page.md"
16
+
17
+ class_option :at,
18
+ default: DEFAULT_TAG_DIRECTORY,
19
+ desc: "the directory in which to put the tag index pages"
20
+
21
+ class_option :template,
22
+ default: DEFAULT_PATH_TO_TAG_INDEX_PAGE_TEMPLATE,
23
+ desc: "the path to the file defining the tag index page template"
24
+
25
+ desc "now", "update your jekyll blog's tag index pages"
26
+
27
+ def now
28
+ UpdateTags.update(
29
+ tag_directory: options[:at],
30
+ path_to_tag_index_page_template: options[:template],
31
+ )
32
+ end
33
+
34
+ desc "continuously", "update your jekyll blog's tag index pages continuously"
35
+
36
+ def continuously
37
+ UpdateTags.update(
38
+ tag_directory: options[:at],
39
+ path_to_tag_index_page_template: options[:template],
40
+ )
41
+
42
+ Filewatcher.new(["_posts", "_building", "_writing", "_notes", options[:template]]).watch do |changes|
43
+ UpdateTags.update(
44
+ tag_directory: options[:at],
45
+ path_to_tag_index_page_template: options[:template],
46
+ )
47
+ end
48
+ end
49
+ end
50
+
51
+ UpdateTagsCli.start(ARGV)
metadata ADDED
@@ -0,0 +1,103 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: custom_update_tags
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.2
5
+ platform: ruby
6
+ authors:
7
+ - Nick Pachulski
8
+ - Thomas
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2024-04-09 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: thor
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "~>"
19
+ - !ruby/object:Gem::Version
20
+ version: 1.2.1
21
+ type: :runtime
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "~>"
26
+ - !ruby/object:Gem::Version
27
+ version: 1.2.1
28
+ - !ruby/object:Gem::Dependency
29
+ name: fileutils
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - "~>"
33
+ - !ruby/object:Gem::Version
34
+ version: 1.6.0
35
+ type: :runtime
36
+ prerelease: false
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - "~>"
40
+ - !ruby/object:Gem::Version
41
+ version: 1.6.0
42
+ - !ruby/object:Gem::Dependency
43
+ name: filewatcher
44
+ requirement: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - "~>"
47
+ - !ruby/object:Gem::Version
48
+ version: 2.0.0
49
+ type: :runtime
50
+ prerelease: false
51
+ version_requirements: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - "~>"
54
+ - !ruby/object:Gem::Version
55
+ version: 2.0.0
56
+ - !ruby/object:Gem::Dependency
57
+ name: front_matter_parser
58
+ requirement: !ruby/object:Gem::Requirement
59
+ requirements:
60
+ - - "~>"
61
+ - !ruby/object:Gem::Version
62
+ version: 1.0.1
63
+ type: :runtime
64
+ prerelease: false
65
+ version_requirements: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - "~>"
68
+ - !ruby/object:Gem::Version
69
+ version: 1.0.1
70
+ description: Automatically update your jekyll blog's tag index pages for GitHub Pages
71
+ email:
72
+ - nick@pachulski.me
73
+ - tpradainfo@gmail.com
74
+ executables:
75
+ - update_tags
76
+ extensions: []
77
+ extra_rdoc_files: []
78
+ files:
79
+ - bin/update_tags
80
+ homepage: https://github.com/pachun/update_tags
81
+ licenses:
82
+ - MIT
83
+ metadata: {}
84
+ post_install_message:
85
+ rdoc_options: []
86
+ require_paths:
87
+ - lib
88
+ required_ruby_version: !ruby/object:Gem::Requirement
89
+ requirements:
90
+ - - ">="
91
+ - !ruby/object:Gem::Version
92
+ version: '0'
93
+ required_rubygems_version: !ruby/object:Gem::Requirement
94
+ requirements:
95
+ - - ">="
96
+ - !ruby/object:Gem::Version
97
+ version: '0'
98
+ requirements: []
99
+ rubygems_version: 3.4.19
100
+ signing_key:
101
+ specification_version: 4
102
+ summary: Jekyll blog post tags for GitHub Pages
103
+ test_files: []