pinboard_logseq 0.1.0 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop.yml +17 -0
- data/Gemfile.lock +10 -2
- data/README.md +5 -4
- data/exe/pinboard_logseq +1 -1
- data/lib/pinboard_logseq/cli.rb +2 -2
- data/lib/pinboard_logseq/pin.rb +7 -7
- data/lib/pinboard_logseq/version.rb +1 -1
- data/pinboard_logseq.gemspec +20 -17
- metadata +45 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d113b747303e4547c9bf26b1ebd3a2f36ae1a7df0d8b44bab480b18122e2eb11
|
4
|
+
data.tar.gz: d795dd056494aca6e32773749b246265e16f97e74fcd6ebe76eca205523c198a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0ef563f88444b2fd23a2efea32cc132aa350debfc4d537fd05e7eec8d058dbfdfe80f67575dea2049440e22caa31da71ac4f118ac7a2789e6fbe789ab0ce2b47
|
7
|
+
data.tar.gz: 96cbbe580fd0c994e433330019533670deba1b137299c3b049c1271a45f426caf0538e3f2203ca131b9bbda0eaaa037a2dc7286b2d3c6ebc9ed6a7ac0969dc05
|
data/.rubocop.yml
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# based on https://evilmartians.com/chronicles/rubocoping-with-legacy-bring-your-ruby-code-up-to-standard
|
2
|
+
|
3
|
+
inherit_mode:
|
4
|
+
merge:
|
5
|
+
- Exclude
|
6
|
+
|
7
|
+
require:
|
8
|
+
- rubocop-minitest
|
9
|
+
- rubocop-performance
|
10
|
+
- rubocop-rake
|
11
|
+
- standard
|
12
|
+
|
13
|
+
inherit_gem:
|
14
|
+
standard: config/base.yml
|
15
|
+
|
16
|
+
AllCops:
|
17
|
+
NewCops: disable
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
pinboard_logseq (0.1.
|
4
|
+
pinboard_logseq (0.1.2)
|
5
5
|
activesupport
|
6
6
|
sorbet-runtime
|
7
7
|
|
@@ -47,14 +47,19 @@ GEM
|
|
47
47
|
unicode-display_width (>= 1.4.0, < 3.0)
|
48
48
|
rubocop-ast (1.24.0)
|
49
49
|
parser (>= 3.1.1.0)
|
50
|
+
rubocop-minitest (0.23.2)
|
51
|
+
rubocop (>= 0.90, < 2.0)
|
50
52
|
rubocop-performance (1.15.1)
|
51
53
|
rubocop (>= 1.7.0, < 2.0)
|
52
54
|
rubocop-ast (>= 0.4.0)
|
55
|
+
rubocop-rake (0.6.0)
|
56
|
+
rubocop (~> 1.0)
|
53
57
|
ruby-progressbar (1.11.0)
|
54
58
|
sorbet (0.5.10595)
|
55
59
|
sorbet-static (= 0.5.10595)
|
56
|
-
sorbet-runtime (0.5.
|
60
|
+
sorbet-runtime (0.5.10597)
|
57
61
|
sorbet-static (0.5.10595-universal-darwin-21)
|
62
|
+
sorbet-static (0.5.10595-x86_64-linux)
|
58
63
|
standard (1.19.1)
|
59
64
|
language_server-protocol (~> 3.17.0.2)
|
60
65
|
rubocop (= 1.39.0)
|
@@ -65,12 +70,15 @@ GEM
|
|
65
70
|
|
66
71
|
PLATFORMS
|
67
72
|
arm64-darwin-21
|
73
|
+
x86_64-linux
|
68
74
|
|
69
75
|
DEPENDENCIES
|
70
76
|
debug
|
71
77
|
minitest (~> 5.0)
|
72
78
|
pinboard_logseq!
|
73
79
|
rake (~> 13.0)
|
80
|
+
rubocop-minitest
|
81
|
+
rubocop-rake
|
74
82
|
sorbet
|
75
83
|
standard (~> 1.3)
|
76
84
|
|
data/README.md
CHANGED
@@ -1,11 +1,12 @@
|
|
1
1
|
# pinboard_logseq
|
2
2
|
|
3
|
-
This gem consumes
|
3
|
+
This gem consumes a JSON export from Pinboard, and generates a set of Markdown pages suitable for Logseq.
|
4
4
|
|
5
|
-
It generates
|
6
|
-
`output/`.
|
5
|
+
It generates separate pages corresponding to each month in your Pinboard data. The files are saved to the `output/` directory.
|
7
6
|
|
8
|
-
|
7
|
+
Each Pinboard tag is converted to a Logseq `[[reference]]`, and is linked to the corresponding date page, e.g. `[[Dec 1st, 2022]]`.
|
8
|
+
|
9
|
+
Once generated, you can import the files into Logseq by copying or moving them into your Logseq graph's `pages/` directory.
|
9
10
|
|
10
11
|
If you have a large number of bookmarks, you may want to do this in stages, since it can cause Logseq to become
|
11
12
|
unresponsive.
|
data/exe/pinboard_logseq
CHANGED
data/lib/pinboard_logseq/cli.rb
CHANGED
@@ -33,8 +33,8 @@ module PinboardLogseq
|
|
33
33
|
day = pin.time.day.ordinalize
|
34
34
|
formatted_date = "#{month_name_short} #{day}, #{year}"
|
35
35
|
content +=
|
36
|
-
"- 🔖 #{pin.description || "No description"}](#{pin.href}) [[#{formatted_date}]] "
|
37
|
-
content += "\n> #{pin.extended}" if pin.extended && pin.extended != ""
|
36
|
+
"- 🔖 [#{pin.description || "No description"}](#{pin.href}) [[#{formatted_date}]] "
|
37
|
+
content += "\n> #{pin.extended}" if pin.extended && pin.extended != "" && pin.extended != "undefined"
|
38
38
|
tag_bits = pin.tags.map { |t| "[[#{t}]]" }
|
39
39
|
tag_bits << "[[Pinboard - To Read]]" if pin.to_read
|
40
40
|
content += tag_bits.join(" ")
|
data/lib/pinboard_logseq/pin.rb
CHANGED
data/pinboard_logseq.gemspec
CHANGED
@@ -1,21 +1,21 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require_relative
|
3
|
+
require_relative "lib/pinboard_logseq/version"
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
|
-
spec.name =
|
6
|
+
spec.name = "pinboard_logseq"
|
7
7
|
spec.version = PinboardLogseq::VERSION
|
8
|
-
spec.authors = [
|
9
|
-
spec.email = [
|
8
|
+
spec.authors = ["Andy Waite"]
|
9
|
+
spec.email = ["andyw8@users.noreply.github.com"]
|
10
10
|
|
11
|
-
spec.summary =
|
12
|
-
spec.homepage =
|
13
|
-
spec.license =
|
14
|
-
spec.required_ruby_version =
|
11
|
+
spec.summary = "Export from Pinboard to Logseq"
|
12
|
+
spec.homepage = "https://github.com/andyw8/pinboard_logseq"
|
13
|
+
spec.license = "MIT"
|
14
|
+
spec.required_ruby_version = ">= 2.6.0"
|
15
15
|
|
16
|
-
spec.metadata[
|
16
|
+
spec.metadata["allowed_push_host"] = "https://rubygems.org"
|
17
17
|
|
18
|
-
spec.metadata[
|
18
|
+
spec.metadata["homepage_uri"] = spec.homepage
|
19
19
|
|
20
20
|
# Specify which files should be added to the gem when it is released.
|
21
21
|
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
@@ -24,14 +24,17 @@ Gem::Specification.new do |spec|
|
|
24
24
|
(f == __FILE__) || f.match(%r{\A(?:(?:bin|test|spec|features)/|\.(?:git|travis|circleci)|appveyor)})
|
25
25
|
end
|
26
26
|
end
|
27
|
-
spec.bindir =
|
27
|
+
spec.bindir = "exe"
|
28
28
|
spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
|
29
|
-
spec.require_paths = [
|
30
|
-
|
31
|
-
spec.add_dependency
|
32
|
-
spec.add_dependency
|
33
|
-
spec.add_development_dependency
|
34
|
-
spec.add_development_dependency
|
29
|
+
spec.require_paths = ["lib"]
|
30
|
+
|
31
|
+
spec.add_dependency "activesupport"
|
32
|
+
spec.add_dependency "sorbet-runtime"
|
33
|
+
spec.add_development_dependency "debug"
|
34
|
+
spec.add_development_dependency "sorbet"
|
35
|
+
spec.add_development_dependency "standard"
|
36
|
+
spec.add_development_dependency "rubocop-minitest"
|
37
|
+
spec.add_development_dependency "rubocop-rake"
|
35
38
|
|
36
39
|
# For more information and examples about making a new gem, check out our
|
37
40
|
# guide at: https://bundler.io/guides/creating_gem.html
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pinboard_logseq
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andy Waite
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-12-
|
11
|
+
date: 2022-12-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -66,6 +66,48 @@ dependencies:
|
|
66
66
|
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: standard
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: rubocop-minitest
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: rubocop-rake
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
69
111
|
description:
|
70
112
|
email:
|
71
113
|
- andyw8@users.noreply.github.com
|
@@ -74,6 +116,7 @@ executables:
|
|
74
116
|
extensions: []
|
75
117
|
extra_rdoc_files: []
|
76
118
|
files:
|
119
|
+
- ".rubocop.yml"
|
77
120
|
- ".standard.yml"
|
78
121
|
- Gemfile
|
79
122
|
- Gemfile.lock
|