sublime_text_kit 11.0.0 → 11.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/README.adoc +40 -31
- data/lib/sublime_text_kit/cli/actions/snippets.rb +3 -1
- data/lib/sublime_text_kit/cli/parsers/core.rb +7 -3
- data/lib/sublime_text_kit/identity.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f09a97c9c7bd65b2e03cbcd38b5d7eea709ee4a253e6be57ac3101d948f7a3df
|
4
|
+
data.tar.gz: 4eb97c05c9d833826fcab6ddb812fa33ca94a9b595d991066247250dcfc0682c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e7035860e908e521ec4445ceaa7bb8d3dcfa10974aa6885dba538c214e8a8c531550c596556c9e3d9d13bd181116c8ec2a4a4c9f075e5c8dea8125daccdf5289
|
7
|
+
data.tar.gz: '0385887b44d98e5742e5b8a1a277a518886d119700ba76b2d143349dfc4db8a7973ea94f7e76e23918e6c1c45ab0d920861fce3000645997d21a4382e0582729'
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/README.adoc
CHANGED
@@ -12,18 +12,19 @@ image::https://img.shields.io/badge/code_style-alchemists-brightgreen.svg[Alchem
|
|
12
12
|
image::https://circleci.com/gh/bkuhlmann/sublime_text_kit.svg?style=svg[Circle CI Status]
|
13
13
|
|
14
14
|
Sublime Text Kit is a command line interface for managing Sublime Text metadata for multiple
|
15
|
-
projects, sessions, etc.
|
16
|
-
|
15
|
+
projects, sessions, snippets, etc. This allows you to avoiding manual maintenance of your workspace
|
16
|
+
so you can stay focused on your own work.
|
17
17
|
|
18
18
|
toc::[]
|
19
19
|
|
20
20
|
== Features
|
21
21
|
|
22
|
-
*
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
22
|
+
* Manages project metadata (`.sublime-project` and `.sublime-workspace` files).
|
23
|
+
* Manages session metadata so you can quickly toggle between projects via the `CONTROL+COMMAND+p`
|
24
|
+
shortcut.
|
25
|
+
* Prints all of your custom snippets in either
|
26
|
+
link:https://daringfireball.net/projects/markdown[Markdown] or
|
27
|
+
link:https://asciidoctor.org[ASCII Doc] format.
|
27
28
|
|
28
29
|
== Requirements
|
29
30
|
|
@@ -49,10 +50,10 @@ From the command line, type: `sublime_text_kit`
|
|
49
50
|
USAGE:
|
50
51
|
-c, --config ACTION Manage gem configuration. Actions: edit or view.
|
51
52
|
-h, --help Show this message.
|
52
|
-
-m, --metadata ACTION Manage metadata. Actions: create, delete, or recreate.
|
53
|
-
-S, --session Rebuild session.
|
54
|
-
-s, --snippets [FORMAT] View snippets. Default:
|
55
|
-
-u, --update Update
|
53
|
+
-m, --metadata ACTION Manage project metadata. Actions: create, delete, or recreate.
|
54
|
+
-S, --session Rebuild session metadata.
|
55
|
+
-s, --snippets [FORMAT] View snippets. Default: ascii_doc. Formats: markdown or ascii_doc.
|
56
|
+
-u, --update Update project and session metadata based on current settings.
|
56
57
|
-v, --version Show gem version.
|
57
58
|
....
|
58
59
|
|
@@ -67,26 +68,26 @@ An example configuration could be:
|
|
67
68
|
[source,yaml]
|
68
69
|
----
|
69
70
|
:project_roots:
|
70
|
-
- "~/Engineering/
|
71
|
+
- "~/Engineering/Organizations"
|
71
72
|
- "~/Engineering/OSS"
|
72
73
|
:metadata_dir: "~/Dropbox/Cache/Sublime"
|
73
74
|
:snippets_format: :ascii_doc
|
74
75
|
----
|
75
76
|
|
76
|
-
Feel free to take this configuration, modify, and save as your own
|
77
|
+
Feel free to take this configuration, modify, and save as your own.
|
77
78
|
|
78
|
-
The
|
79
|
-
metadata (i.e. `.sublime-project`, `.sublime-workspace`) is generated, the name of the
|
80
|
-
will be the same name as
|
81
|
-
location, is written to the same metadata directory
|
82
|
-
assuming the following directory structure exists…
|
79
|
+
The `project_roots` key defines the root level directories where your project folders are located.
|
80
|
+
When project metadata (i.e. `.sublime-project`, `.sublime-workspace`) is generated, the name of the
|
81
|
+
metadata file will be the same name as the project folder. All project metadata, regardless of root
|
82
|
+
location, is written to the same metadata directory as defined by the `metadata_dir` key. If using
|
83
|
+
the example settings shown above and assuming the following directory structure exists…
|
83
84
|
|
84
85
|
....
|
85
86
|
~/Engineering/OSS/example
|
86
87
|
~/Engineering/OSS/sublime_text_kit
|
87
88
|
....
|
88
89
|
|
89
|
-
|
90
|
+
...project metadata will be created in the `metadata_dir` as follows:
|
90
91
|
|
91
92
|
....
|
92
93
|
~/Dropbox/Cache/Sublime/example.sublime-project
|
@@ -95,25 +96,33 @@ assuming the following directory structure exists…
|
|
95
96
|
~/Dropbox/Cache/Sublime/sublime_text_kit.sublime-workspace
|
96
97
|
....
|
97
98
|
|
99
|
+
The `snippets_format` key allows you define what format to print your snippets as. The default
|
100
|
+
format is Markdown but you can switch to ASCII Doc too. You can always override your default
|
101
|
+
configuration by specifying the format from the command line: `sublime_text_kit -s ascii_doc`. For
|
102
|
+
example, this is how link:https://www.alchemists.io/projects/sublime_text_setup/#_snippets[snippets
|
103
|
+
documentation] is genereted for the
|
104
|
+
link:https://www.alchemists.io/projects/sublime_text_setup[Sublime Text Setup] project.
|
105
|
+
|
98
106
|
=== Workflow
|
99
107
|
|
100
108
|
The following demonstrates a default Sublime Text setup:
|
101
109
|
|
102
|
-
.
|
103
|
-
|
104
|
-
.
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
. Breeze through your project workload with ease. 🎉
|
110
|
+
1. Start by defining your configuration: `sublime_text_kit --config edit`.
|
111
|
+
1. Shutdown Sublime Text (i.e. `COMMAND+q`).
|
112
|
+
1. Run `sublime_text_kit --update` which will create project metadata and rebuild session metadata
|
113
|
+
so Sublime Text has a complete project history from which to switch between via the
|
114
|
+
`CONTROL+COMMMAND+p` shortcut.
|
115
|
+
1. Launch Sublime Text and use the `CONTROL+COMMAND+p` keyboard shortcut to toggle between projects.
|
116
|
+
Notice that you can (fuzzy type) project names to jump between them.
|
117
|
+
1. Navigate through your project workload with ease. 🎉
|
111
118
|
|
112
119
|
=== Troubleshooting
|
113
120
|
|
114
|
-
* When rebuilding
|
115
|
-
|
116
|
-
|
121
|
+
* When rebuilding your session, ensure Sublime Text is shut down or changes might not be applied
|
122
|
+
properly.
|
123
|
+
* When rebuilding project metadata, ensure the `metadata_dir` -- as defined via your configuration
|
124
|
+
-- points to an existing directory which can contain `.sublime-project` and `.sublime-workspace`
|
125
|
+
files.
|
117
126
|
|
118
127
|
== Development
|
119
128
|
|
@@ -19,13 +19,15 @@ module SublimeTextKit
|
|
19
19
|
kind = configuration.snippets_format
|
20
20
|
printers.fetch(kind).call
|
21
21
|
rescue KeyError
|
22
|
-
logger.error { "Invalid snippet format: #{kind}." }
|
22
|
+
logger.error { "Invalid snippet format (must be a symbol): #{kind}. Use: #{formats}." }
|
23
23
|
end
|
24
24
|
|
25
25
|
private
|
26
26
|
|
27
27
|
attr_reader :printers, :container
|
28
28
|
|
29
|
+
def formats = printers.keys.map(&:inspect).join(" or ")
|
30
|
+
|
29
31
|
def configuration = container[__method__]
|
30
32
|
|
31
33
|
def logger = container[__method__]
|
@@ -44,14 +44,14 @@ module SublimeTextKit
|
|
44
44
|
"-m",
|
45
45
|
"--metadata ACTION",
|
46
46
|
%i[create delete recreate],
|
47
|
-
"Manage metadata. Actions: create, delete, or recreate."
|
47
|
+
"Manage project metadata. Actions: create, delete, or recreate."
|
48
48
|
) do |action|
|
49
49
|
configuration.action_metadata = action
|
50
50
|
end
|
51
51
|
end
|
52
52
|
|
53
53
|
def add_session
|
54
|
-
client.on "-S", "--session", "Rebuild session." do
|
54
|
+
client.on "-S", "--session", "Rebuild session metadata." do
|
55
55
|
configuration.action_session = true
|
56
56
|
end
|
57
57
|
end
|
@@ -70,7 +70,11 @@ module SublimeTextKit
|
|
70
70
|
end
|
71
71
|
|
72
72
|
def add_update
|
73
|
-
client.on
|
73
|
+
client.on(
|
74
|
+
"-u",
|
75
|
+
"--update",
|
76
|
+
"Update project and session metadata based on current settings."
|
77
|
+
) do
|
74
78
|
configuration.action_update = true
|
75
79
|
end
|
76
80
|
end
|
@@ -5,7 +5,7 @@ module SublimeTextKit
|
|
5
5
|
module Identity
|
6
6
|
NAME = "sublime_text_kit"
|
7
7
|
LABEL = "Sublime Text Kit"
|
8
|
-
VERSION = "11.0.
|
8
|
+
VERSION = "11.0.1"
|
9
9
|
VERSION_LABEL = "#{LABEL} #{VERSION}".freeze
|
10
10
|
SUMMARY = "A command line interface for managing Sublime Text metadata."
|
11
11
|
end
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sublime_text_kit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 11.0.
|
4
|
+
version: 11.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -28,7 +28,7 @@ cert_chain:
|
|
28
28
|
lkHilIrX69jq8wMPpBhlaw2mRmeSL50Wv5u6xVBvOHhXFSP1crXM95vfLhLyRYod
|
29
29
|
W2A=
|
30
30
|
-----END CERTIFICATE-----
|
31
|
-
date: 2021-10-
|
31
|
+
date: 2021-10-09 00:00:00.000000000 Z
|
32
32
|
dependencies:
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: dry-container
|
metadata.gz.sig
CHANGED
Binary file
|