GithubHelp home page GithubHelp logo

serpentbytes / siteit Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 4.0 1.42 MB

Easy-to-use Static Site Generator that can turn `.txt` files into HTML.

Home Page: https://siteit.vercel.app

License: MIT License

JavaScript 95.39% CSS 3.99% Shell 0.62%
cli ssg javascript markdown-to-html text-to-html static-site-generator text-parser

siteit's Introduction

Siteit

GitHub contributors GitHub issues GitHub open-pull-requests GitHub pull-requests merged Github version

About

Siteit allows users to convert text files into .html pages. Presently, Siteit supports input files in .txt and .md formats.

Installation

npm install -g siteit

Features

Siteit comes with its built-in stylesheet and supports various screen resolutions. When a folder with .txt or .md files is supplied, an Index file is also generated in the dist folder, linking to all generated files.

Usage

Command Option/Flag Additional Argument(s) Description
siteit -v or --version n/a Displays tool name and version information
siteit -h or --help n/a Display usage manual
siteit -i or --input ./filename.(txt or md) Converts the file's content supplied as an additional argument into a .html document. To locate the generated file, cd into the application's dist directory
siteit -i or --input ./directory Converts all the files within a directory supplied as additional argument into .html documents. To locate the generated files, cd into the application's dist directory and open index.html

Usage format: siteit [option/flag] [additional arguments]

Markdown files handling

Siteit fully supports the following markdown features:

name syntax output
Bold text **Some bold Text** <strong>Some bold text<strong/>
" __Some bold text__ <strong>Some bold text<strong/>
Italic text *Some italic text* <em>Some italic text</em>
" _Some italic text_ <em>Some italic text</em>
Deleted text ~~Some deleted text~~ <del>Some italic text</del>
Marked text ==Some marked text== <mark>Some italic text</mark>
Inline Code `Some inline code` <code>Some inline code</code>
Horizontal rule ___ <hr />
" *** <hr />
Heading 1 # Heading <h1>Heading</h1>

Contributing

If you are interested in contributing code to Siteit, see our contribution guidelines here.

siteit's People

Contributors

myrfion avatar ririio avatar serpentbytes avatar

Stargazers

 avatar  avatar

Watchers

 avatar

siteit's Issues

Remove commented code

In my opinion, it would be better to remove commented code, you could always return to previous comments and check what was there. Files, where I found commented code, are: utility.js and htmlGenerator.js

"siteit -i ./source_directory" command generates an error.

Operating Environment

Operation System: Windows 10
Node version: v16.13.2
Command-line shell: PowerShell v5.1.19041.1682

Issue

On my machine, the tool doesn’t run when entering command "siteit -i ./source_directory" as instructed in help guide.
Enter command and output:
image

It does run when running index.js directly:
image

I'm unfortunately not sure whether it's related to my setup or this is a general issue that also occurs for you.

Expected Behaviour

The tool runs like running index.js directly.

Add markdown support for `<hr>`

Feature Request

Add support for the inline horizontal rule.

Details

In the Markdown file, when a single line only contains --- will cause the HTML to render <hr> in its place.

Add the simple markdow support

Feature request

I want to make your tool siteit support conversion of .txt to not only HTML, but also markdown files to HTML.

Features to implement

I want to implement the following markdown feature:

  • Bold text
  • Italic text

The tool doesn't generate output after creation of output folder.

Operating Environment

Operation System: Windows 10
Node version: v16.13.2

Issue

As expected, the tool creates a dist output folder when it doesn't’ exist, but it should also proceed to generate output files in the folder. Instead, the output folder is empty.
Enter command and output:
image

Expected Behaviour

The tool generates output after creation of output folder.

Add Support for Config

Having to write a long command line is always a problem in terms of spelling errors.
That's why I believed that adding a "config" flag would help in terms of making it easier for the user to create a long command line
in a much simpler and elegant way by using JSON

Output folder is always immediately deleted.

Operating Environment

Operation System: Windows 10
Node version: v16.13.2

Issue

The tool always deletes the output folder right after successfully running it without error message. The user can’t access the output files.

Expected Behaviour

The output folder isn't deleted and can be accedes by the user to view the result.

Make revisions based on feeback on 0.1

Issue

Some enhancements to the source code are needed.

Details

  • Use all lower case names for files since not all filesystems are case sensitive.
  • Simplify programmatically displaying information from the package.json file by importing it in the following manner:

const { name, version } = require(‘../package.json’)

The tool reports an issue when reading a single txt file as input.

Operating Environment

Operation System: Windows 10
Node version: v16.13.2

Issue

The tool reports an issue when reading a single txt file as input.
Entered command and output:
image

What’s in the test folder:
image

Expected Behaviour

The tool accepts a single txt file as input and produces a html file as output.

Improve CI

Description

There's room for Improvement in the current CI setup in terms of performance. We could also automate release and play with danger-js

Resource:
https://danger.systems/js/

The tool inaccurately shows error message about invalid source files.

Operating Environment

Operation System: Windows 10
Node version: v16.13.2

Issue

If the dist output folder doesn’t exist, the tool inaccurately shows error message about invalid source files.
When dist folder doesn’t exist:
image

When dist folder exists:
image

Content of the input folder:
image

Expected Behaviour

The tool doesn't show any message about the source files when they are valid, regardless of whether the output folder is missing.

Tool doesn't work with filenames that have space

I tried to run command siteit --input Silver Blaze.txt and got the following error messages:
-- ERROR Invalid or non-existing source supplied -- -- ERROR Invalid or non-existing source supplied --

Add support for inline `<code>` blocks

Feature Request

Add support for inline <code> blocks

Details

In Markdown file , when text is enclosed within a single backtick will cause the HTML to get rendered as <code>... some text...</code>.

README.md instruction is currently missing.

I understand README.md is most likely still a WIP. As of now, it doesn't provide instruction on how to use the tool and what it is. I think you might want to list Node.js and npm package installation as requirements.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.