markleft 0.1.1

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 ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 7629bbb0deff5bdeb11894c8c2dc3a4a55c697cbf3af8402d38d093d5ce2ea75
4
+ data.tar.gz: e2318355783b9919af483419b660119c7d8e44516f20464e5a41eae4747591a7
5
+ SHA512:
6
+ metadata.gz: 6acfcf5631696853f694d2efff3e566cf5a00ad8451b29e856c48326bd47b667114dc6191ff307ab0c6b5623f40a71804240d9e3509db79d37eec07b041f0797
7
+ data.tar.gz: edff09e17f9b2be7501363e247594c34d50f70e2a0dc5ef703690fc20aeac166e343787093fc260bcbcbb485d178a84cbeeaf4108c434d3ca9bdd3a2752761b8
data/.idea/.gitignore ADDED
@@ -0,0 +1,8 @@
1
+ # Default ignored files
2
+ /shelf/
3
+ /workspace.xml
4
+ # Editor-based HTTP Client requests
5
+ /httpRequests/
6
+ # Datasource local storage ignored files
7
+ /dataSources/
8
+ /dataSources.local.xml
@@ -0,0 +1,21 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="RUBY_MODULE" version="4">
3
+ <component name="ModuleRunConfigurationManager">
4
+ <shared />
5
+ </component>
6
+ <component name="NewModuleRootManager">
7
+ <content url="file://$MODULE_DIR$">
8
+ <sourceFolder url="file://$MODULE_DIR$/features" isTestSource="true" />
9
+ <sourceFolder url="file://$MODULE_DIR$/spec" isTestSource="true" />
10
+ <sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
11
+ </content>
12
+ <orderEntry type="jdk" jdkName="ruby-3.2.4-p170" jdkType="RUBY_SDK" />
13
+ <orderEntry type="sourceFolder" forTests="false" />
14
+ <orderEntry type="library" scope="PROVIDED" name="ast (v2.4.2, ruby-3.2.4-p170) [gem]" level="application" />
15
+ <orderEntry type="library" scope="PROVIDED" name="parallel (v1.26.3, ruby-3.2.4-p170) [gem]" level="application" />
16
+ <orderEntry type="library" scope="PROVIDED" name="racc (v1.8.1, ruby-3.2.4-p170) [gem]" level="application" />
17
+ <orderEntry type="library" scope="PROVIDED" name="rainbow (v3.1.1, ruby-3.2.4-p170) [gem]" level="application" />
18
+ <orderEntry type="library" scope="PROVIDED" name="rake (v13.2.1, ruby-3.2.4-p170) [gem]" level="application" />
19
+ <orderEntry type="library" scope="PROVIDED" name="ruby-progressbar (v1.13.0, ruby-3.2.4-p170) [gem]" level="application" />
20
+ </component>
21
+ </module>
@@ -0,0 +1,12 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="MaterialThemeProjectNewConfig">
4
+ <option name="metadata">
5
+ <MTProjectMetadataState>
6
+ <option name="migrated" value="true" />
7
+ <option name="pristineConfig" value="false" />
8
+ <option name="userId" value="1c3d9eb4:1904b29008d:-7ffe" />
9
+ </MTProjectMetadataState>
10
+ </option>
11
+ </component>
12
+ </project>
data/.idea/modules.xml ADDED
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectModuleManager">
4
+ <modules>
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/markleft.iml" filepath="$PROJECT_DIR$/.idea/markleft.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
data/.idea/vcs.xml ADDED
@@ -0,0 +1,6 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
+ </component>
6
+ </project>
data/.rubocop.yml ADDED
@@ -0,0 +1,8 @@
1
+ AllCops:
2
+ TargetRubyVersion: 3.0
3
+
4
+ Style/StringLiterals:
5
+ EnforcedStyle: double_quotes
6
+
7
+ Style/StringLiteralsInInterpolation:
8
+ EnforcedStyle: double_quotes
data/CHANGELOG.md ADDED
@@ -0,0 +1,5 @@
1
+ # Changelog
2
+
3
+
4
+
5
+ \* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)*
@@ -0,0 +1,132 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ We as members, contributors, and leaders pledge to make participation in our
6
+ community a harassment-free experience for everyone, regardless of age, body
7
+ size, visible or invisible disability, ethnicity, sex characteristics, gender
8
+ identity and expression, level of experience, education, socio-economic status,
9
+ nationality, personal appearance, race, caste, color, religion, or sexual
10
+ identity and orientation.
11
+
12
+ We pledge to act and interact in ways that contribute to an open, welcoming,
13
+ diverse, inclusive, and healthy community.
14
+
15
+ ## Our Standards
16
+
17
+ Examples of behavior that contributes to a positive environment for our
18
+ community include:
19
+
20
+ * Demonstrating empathy and kindness toward other people
21
+ * Being respectful of differing opinions, viewpoints, and experiences
22
+ * Giving and gracefully accepting constructive feedback
23
+ * Accepting responsibility and apologizing to those affected by our mistakes,
24
+ and learning from the experience
25
+ * Focusing on what is best not just for us as individuals, but for the overall
26
+ community
27
+
28
+ Examples of unacceptable behavior include:
29
+
30
+ * The use of sexualized language or imagery, and sexual attention or advances of
31
+ any kind
32
+ * Trolling, insulting or derogatory comments, and personal or political attacks
33
+ * Public or private harassment
34
+ * Publishing others' private information, such as a physical or email address,
35
+ without their explicit permission
36
+ * Other conduct which could reasonably be considered inappropriate in a
37
+ professional setting
38
+
39
+ ## Enforcement Responsibilities
40
+
41
+ Community leaders are responsible for clarifying and enforcing our standards of
42
+ acceptable behavior and will take appropriate and fair corrective action in
43
+ response to any behavior that they deem inappropriate, threatening, offensive,
44
+ or harmful.
45
+
46
+ Community leaders have the right and responsibility to remove, edit, or reject
47
+ comments, commits, code, wiki edits, issues, and other contributions that are
48
+ not aligned to this Code of Conduct, and will communicate reasons for moderation
49
+ decisions when appropriate.
50
+
51
+ ## Scope
52
+
53
+ This Code of Conduct applies within all community spaces, and also applies when
54
+ an individual is officially representing the community in public spaces.
55
+ Examples of representing our community include using an official email address,
56
+ posting via an official social media account, or acting as an appointed
57
+ representative at an online or offline event.
58
+
59
+ ## Enforcement
60
+
61
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
62
+ reported to the community leaders responsible for enforcement at
63
+ [INSERT CONTACT METHOD].
64
+ All complaints will be reviewed and investigated promptly and fairly.
65
+
66
+ All community leaders are obligated to respect the privacy and security of the
67
+ reporter of any incident.
68
+
69
+ ## Enforcement Guidelines
70
+
71
+ Community leaders will follow these Community Impact Guidelines in determining
72
+ the consequences for any action they deem in violation of this Code of Conduct:
73
+
74
+ ### 1. Correction
75
+
76
+ **Community Impact**: Use of inappropriate language or other behavior deemed
77
+ unprofessional or unwelcome in the community.
78
+
79
+ **Consequence**: A private, written warning from community leaders, providing
80
+ clarity around the nature of the violation and an explanation of why the
81
+ behavior was inappropriate. A public apology may be requested.
82
+
83
+ ### 2. Warning
84
+
85
+ **Community Impact**: A violation through a single incident or series of
86
+ actions.
87
+
88
+ **Consequence**: A warning with consequences for continued behavior. No
89
+ interaction with the people involved, including unsolicited interaction with
90
+ those enforcing the Code of Conduct, for a specified period of time. This
91
+ includes avoiding interactions in community spaces as well as external channels
92
+ like social media. Violating these terms may lead to a temporary or permanent
93
+ ban.
94
+
95
+ ### 3. Temporary Ban
96
+
97
+ **Community Impact**: A serious violation of community standards, including
98
+ sustained inappropriate behavior.
99
+
100
+ **Consequence**: A temporary ban from any sort of interaction or public
101
+ communication with the community for a specified period of time. No public or
102
+ private interaction with the people involved, including unsolicited interaction
103
+ with those enforcing the Code of Conduct, is allowed during this period.
104
+ Violating these terms may lead to a permanent ban.
105
+
106
+ ### 4. Permanent Ban
107
+
108
+ **Community Impact**: Demonstrating a pattern of violation of community
109
+ standards, including sustained inappropriate behavior, harassment of an
110
+ individual, or aggression toward or disparagement of classes of individuals.
111
+
112
+ **Consequence**: A permanent ban from any sort of public interaction within the
113
+ community.
114
+
115
+ ## Attribution
116
+
117
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118
+ version 2.1, available at
119
+ [https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
120
+
121
+ Community Impact Guidelines were inspired by
122
+ [Mozilla's code of conduct enforcement ladder][Mozilla CoC].
123
+
124
+ For answers to common questions about this code of conduct, see the FAQ at
125
+ [https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
126
+ [https://www.contributor-covenant.org/translations][translations].
127
+
128
+ [homepage]: https://www.contributor-covenant.org
129
+ [v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
130
+ [Mozilla CoC]: https://github.com/mozilla/diversity
131
+ [FAQ]: https://www.contributor-covenant.org/faq
132
+ [translations]: https://www.contributor-covenant.org/translations
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2025 greeenboi
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,91 @@
1
+ # MarkLeft: A Superset to Markdown-to-HTML Compilers
2
+
3
+ ![image](https://github.com/user-attachments/assets/b73b1753-8b48-4036-a0e3-8b1fba47d223)
4
+
5
+
6
+ ## Overview
7
+
8
+ MarkLeft is a powerful and flexible tool designed to extend the capabilities of traditional Markdown-to-HTML compilers. It introduces additional syntax and features to enhance the expressiveness and functionality of Markdown documents.
9
+
10
+ ## Project Structure
11
+
12
+ - `Gemfile` and `Gemfile.lock`: Manage gem dependencies.
13
+ - `markleft-main.rb`: Script for converting Markdown to HTML.
14
+ - `terminal.rb`: TUI for converting Markdown to HTML.
15
+ - `lib/`: Contains the tokenizer, parser, and generator classes.
16
+
17
+ ## Features
18
+
19
+ - **Extended Syntax**: Supports additional formatting options such as bold, italics, and more.
20
+ - **Custom Nodes**: Allows the creation of custom nodes to represent different types of content.
21
+ - **Tokenization and Parsing**: Efficiently tokenizes and parses Markdown content into a structured node tree.
22
+ - **Easy Integration**: Can be easily integrated into existing projects and workflows.
23
+
24
+ ## Prerequisites
25
+
26
+ - Ruby >~ 3.2.4
27
+ - Bundler =2.6.3
28
+
29
+ ## Installation
30
+
31
+ To install MarkLeft, clone the repository and navigate to the project directory:
32
+
33
+ 1. Clone the repository:
34
+ ```sh
35
+ git clone https://github.com/yourusername/markdown-to-html.git
36
+ cd markdown-to-html
37
+ ```
38
+
39
+ 2. Install the dependencies:
40
+ ```sh
41
+ bundle install
42
+ ```
43
+
44
+ ## Running the Converter
45
+
46
+ ### Using `markleft-main.rb`
47
+
48
+ The `markleft-main.rb` file is a simple script that reads a Markdown file, tokenizes it, parses it, and generates HTML output.
49
+
50
+ 1. Run the script:
51
+ ```sh
52
+ ruby markleft-main.rb
53
+ ```
54
+
55
+ 2. Enter the name of the Markdown file when prompted.
56
+
57
+ ### Using `terminal.rb` (TUI)
58
+
59
+ The `terminal.rb` file provides a Text User Interface (TUI) for selecting and processing Markdown files.
60
+
61
+ 1. Run the script:
62
+ ```sh
63
+ ruby terminal.rb
64
+ ```
65
+
66
+ 2. Follow the prompts to select a Markdown file and process it.
67
+
68
+
69
+
70
+ ## Example
71
+
72
+ Given a sample Markdown file `sample.md`:
73
+
74
+ ```markdown
75
+ This is a sample *Markdown* file
76
+ **bold** yippee!
77
+ ```
78
+
79
+ ## Contributing
80
+
81
+ We welcome contributions to enhance MarkLeft. Please fork the repository and submit pull requests with your improvements.
82
+
83
+ ## License
84
+
85
+ This project is licensed under the MIT License. See the `LICENSE` file for details.
86
+
87
+ ## Contact
88
+
89
+ For any questions or feedback, please contact [contact@suvangs.tech](mailto:contact@suvangs.tech).
90
+
91
+ ---
data/Rakefile ADDED
@@ -0,0 +1,12 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "bundler/gem_tasks"
4
+ require "minitest/markleft_task"
5
+
6
+ Minitest::MarkleftTask.create
7
+
8
+ require "rubocop/rake_task"
9
+
10
+ RuboCop::RakeTask.new
11
+
12
+ task default: %i[test rubocop]
data/exe/markleft ADDED
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ require "markleft"
@@ -0,0 +1,5 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Markleft
4
+ VERSION = "0.1.1"
5
+ end
data/lib/markleft.rb ADDED
@@ -0,0 +1,213 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "cli/ui"
4
+ require "fileutils"
5
+ require_relative "markleft/version"
6
+
7
+ module Markleft
8
+ # ----------------- Tokenizer Module ----------------- #
9
+ class Tokenizer
10
+ TOKEN_TYPES = [
11
+ [:bold, /((?<!\s)\*\*(?!\s)(?:[^*]+?|(?:[^*]*(?:(?:\*[^*]*){2})+?)+?)(?<!\s)\*\*)/],
12
+ [:italics, /((?<!\s)\*(?!\s)(?:(?:[^**]*(?:(?:\*\*[^**]*){2})+?)+?|[^**]+?)(?<!\s)\*)/],
13
+ [:newline, /(\r\n|\r|\n)/],
14
+ [:text, /[^*\n\r]+/]
15
+ ].freeze
16
+
17
+ def initialize(markleft)
18
+ @code = markleft
19
+ end
20
+
21
+ def tokenize
22
+ tokens = []
23
+ until @code.empty?
24
+ tokens << tokenize_one_token
25
+ @code = @code.strip
26
+ end
27
+ tokens
28
+ end
29
+
30
+ def tokenize_one_token
31
+ TOKEN_TYPES.each do |type, re|
32
+ re = /\A(#{re})/
33
+ next unless @code =~ re
34
+
35
+ value = ::Regexp.last_match(1)
36
+ @code = @code[value.length..]
37
+ return Token.new(type, value)
38
+ end
39
+ raise "Unexpected character #{@code.inspect}"
40
+ end
41
+ end
42
+
43
+ # ----------------- Parser Module ----------------- #
44
+
45
+ class Parser
46
+ def initialize(tokens)
47
+ @tokens = tokens
48
+ end
49
+
50
+ def parse
51
+ nodes = []
52
+ nodes << parse_node until @tokens.empty?
53
+ nodes
54
+ end
55
+
56
+ def parse_node
57
+ case @tokens.first.type
58
+ when :bold
59
+ parse_bold
60
+ when :italics
61
+ parse_italics
62
+ when :newline
63
+ parse_newline
64
+ when :text
65
+ parse_text
66
+ else
67
+ raise "Unexpected token type: #{@tokens.first.type}"
68
+ end
69
+ end
70
+
71
+ def parse_bold
72
+ value = consume(:bold).value
73
+ BoldNode.new(value)
74
+ end
75
+
76
+ def parse_italics
77
+ value = consume(:italics).value
78
+ ItalicsNode.new(value)
79
+ end
80
+
81
+ def parse_newline
82
+ consume(:newline)
83
+ NewlineNode.new
84
+ end
85
+
86
+ def parse_text
87
+ value = consume(:text).value
88
+ TextNode.new(value)
89
+ end
90
+
91
+ def consume(expected_type)
92
+ token = @tokens.shift
93
+ unless token.type == expected_type
94
+ raise "Expected token type #{expected_type.inspect} but got #{token.type.inspect}"
95
+ end
96
+
97
+ token
98
+ end
99
+ end
100
+
101
+ # ----------------- Code Generator Module ----------------- #
102
+
103
+ class Generator
104
+ def generate(node)
105
+ case node
106
+ when BoldNode
107
+ generate_bold(node)
108
+ when ItalicsNode
109
+ generate_italics(node)
110
+ when NewlineNode
111
+ generate_newline(node)
112
+ when TextNode
113
+ generate_text(node)
114
+ else
115
+ raise "Unexpected node type: #{node.class}"
116
+ end
117
+ end
118
+
119
+ def generate_bold(node)
120
+ "<b>#{node.value}</b>"
121
+ end
122
+
123
+ def generate_italics(node)
124
+ "<i>#{node.value}</i>"
125
+ end
126
+
127
+ def generate_newline(_node)
128
+ "<br>"
129
+ end
130
+
131
+ def generate_text(node)
132
+ node.value
133
+ end
134
+
135
+ def generate_all(nodes)
136
+ nodes.map { |node| generate(node) }.join
137
+ end
138
+ end
139
+
140
+ # ----------------- Error handler ----------------- #
141
+ class Error < StandardError; end
142
+ # ----------------- Nodes ----------------- #
143
+
144
+ Token = Struct.new(:type, :value)
145
+ BoldNode = Struct.new(:value)
146
+ ItalicsNode = Struct.new(:value)
147
+ NewlineNode = Struct.new(:value)
148
+ TextNode = Struct.new(:value)
149
+
150
+ # ----------------- Main Block ----------------- #
151
+
152
+ CLI::UI::StdoutRouter.enable
153
+
154
+ def self.list_md_files
155
+ Dir.glob("*.md")
156
+ end
157
+
158
+ def self.select_md_file(files)
159
+ CLI::UI::Prompt.ask("Select a markdown file to process:") do |handler|
160
+ files.each do |file|
161
+ handler.option(file) { file }
162
+ end
163
+ end
164
+ end
165
+
166
+ def self.process_file(file_name)
167
+ myfile = File.read(file_name)
168
+ html_content = nil
169
+
170
+ CLI::UI::SpinGroup.new do |spin_group|
171
+ spin_group.add("Tokenizing") do |spinner|
172
+ tokenizer = Tokenizer.new(myfile)
173
+ @tokens = tokenizer.tokenize
174
+ spinner.update_title("Tokenizing complete")
175
+ end
176
+
177
+ spin_group.add("Parsing") do |spinner|
178
+ parser = Parser.new(@tokens)
179
+ @node_tree = parser.parse
180
+ spinner.update_title("Parsing complete")
181
+ end
182
+
183
+ spin_group.add("Generating HTML") do |spinner|
184
+ generator = Generator.new.generate_all(@node_tree)
185
+ html_content = generator
186
+ spinner.update_title("HTML generation complete")
187
+ end
188
+ end.wait
189
+
190
+ html_content
191
+ end
192
+
193
+ def self.save_html(file_name, content)
194
+ html_file_name = file_name.sub(/\.md$/, ".html")
195
+ File.write(html_file_name, content)
196
+ html_file_name
197
+ end
198
+
199
+ CLI::UI::Frame.open("Markdown to HTML Converter") do
200
+ files = list_md_files
201
+ if files.empty?
202
+ puts "No markdown files found in the current directory."
203
+ else
204
+ selected_file = select_md_file(files)
205
+ puts "Processing file: #{selected_file}"
206
+ html_content = process_file(selected_file)
207
+ puts "Generated HTML content:"
208
+ puts html_content
209
+ saved_file = save_html(selected_file, html_content)
210
+ puts "HTML content saved to: #{saved_file}"
211
+ end
212
+ end
213
+ end
data/sample.html ADDED
@@ -0,0 +1 @@
1
+ This is a sample <i>*Markdown*</i>file \n<b>**bold**</b>yippee!
data/sample.md ADDED
@@ -0,0 +1,2 @@
1
+ This is a sample *Markdown* file \n
2
+ **bold** yippee!
@@ -0,0 +1,10 @@
1
+ module Markleft
2
+ class Generator
3
+ def generate: (untyped) -> String
4
+ def generate_all: (Array[untyped]) -> String
5
+ def generate_bold: (untyped) -> String
6
+ def generate_italics: (untyped) -> String
7
+ def generate_newline: (untyped) -> String
8
+ def generate_text: (untyped) -> String
9
+ end
10
+ end
@@ -0,0 +1,14 @@
1
+ module Markleft
2
+ class Parser
3
+ @tokens: Array[untyped]
4
+
5
+ def initialize: (Array[untyped]) -> void
6
+ def consume: (Symbol) -> untyped
7
+ def parse: -> Array[untyped]
8
+ def parse_bold: -> untyped
9
+ def parse_italics: -> untyped
10
+ def parse_newline: -> untyped
11
+ def parse_node: -> untyped
12
+ def parse_text: -> untyped
13
+ end
14
+ end
@@ -0,0 +1,12 @@
1
+ module Markleft
2
+
3
+ class Tokenizer
4
+ TOKEN_TYPES: Array[[Symbol, Regexp]]
5
+
6
+ @code: String
7
+
8
+ def initialize: (String) -> void
9
+ def tokenize: -> Array[untyped]
10
+ def tokenize_one_token: -> untyped
11
+ end
12
+ end
data/sig/markleft.rbs ADDED
@@ -0,0 +1,16 @@
1
+ module Markleft
2
+ BoldNode: untyped
3
+ ItalicsNode: untyped
4
+ NewlineNode: untyped
5
+ TextNode: untyped
6
+ Token: untyped
7
+ VERSION: String
8
+ # See the writing guide of rbs: https://github.com/ruby/rbs#guides
9
+ @tokens: untyped
10
+ @node_tree: untyped
11
+
12
+ def self.list_md_files: -> Array[String]
13
+ def self.select_md_file: (Array[String]) -> String
14
+ def self.process_file: (String) -> String
15
+ def self.save_html: (String, String) -> String
16
+ end
metadata ADDED
@@ -0,0 +1,71 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: markleft
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.1
5
+ platform: ruby
6
+ authors:
7
+ - greeenboi
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2025-02-11 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: MarkLeft is a powerful and flexible tool designed to extend the capabilities
14
+ of traditional Markdown-to-HTML compilers. It introduces additional syntax and features
15
+ to enhance the expressiveness and functionality of Markdown documents.
16
+ email:
17
+ - suvan.gowrishanker.204@gmail.com
18
+ executables:
19
+ - markleft
20
+ extensions: []
21
+ extra_rdoc_files: []
22
+ files:
23
+ - ".idea/.gitignore"
24
+ - ".idea/markleft.iml"
25
+ - ".idea/material_theme_project_new.xml"
26
+ - ".idea/modules.xml"
27
+ - ".idea/vcs.xml"
28
+ - ".rubocop.yml"
29
+ - CHANGELOG.md
30
+ - CODE_OF_CONDUCT.md
31
+ - LICENSE.txt
32
+ - README.md
33
+ - Rakefile
34
+ - exe/markleft
35
+ - lib/markleft.rb
36
+ - lib/markleft/version.rb
37
+ - sample.html
38
+ - sample.md
39
+ - sig/markleft.rbs
40
+ - sig/markleft/generator.rbs
41
+ - sig/markleft/parser.rbs
42
+ - sig/markleft/tokenizer.rbs
43
+ homepage: https://github.com/greeenboi/markdown-superset-compiler/tree/master
44
+ licenses:
45
+ - MIT
46
+ metadata:
47
+ homepage_uri: https://github.com/greeenboi/markdown-superset-compiler/tree/master
48
+ github_repo: ssh://github.com/greeenboi/markdown-superset-compiler
49
+ source_code_uri: https://github.com/greeenboi/markdown-superset-compiler/tree/master
50
+ changelog_uri: https://github.com/greeenboi/markdown-superset-compiler/blob/master/CHANGELOG.md
51
+ post_install_message:
52
+ rdoc_options: []
53
+ require_paths:
54
+ - lib
55
+ required_ruby_version: !ruby/object:Gem::Requirement
56
+ requirements:
57
+ - - ">="
58
+ - !ruby/object:Gem::Version
59
+ version: 3.0.0
60
+ required_rubygems_version: !ruby/object:Gem::Requirement
61
+ requirements:
62
+ - - ">="
63
+ - !ruby/object:Gem::Version
64
+ version: '0'
65
+ requirements: []
66
+ rubygems_version: 3.4.19
67
+ signing_key:
68
+ specification_version: 4
69
+ summary: TUI built on ruby to compile gh-flavor and more markdown to html for the
70
+ web to render
71
+ test_files: []