Skip to content

Commit

Permalink
Merge pull request #5 from w4ffl35/feature-update-documentation
Browse files Browse the repository at this point in the history
Updates README and CONTRIBUTING files with more info
  • Loading branch information
w4ffl35 authored Aug 24, 2022
2 parents 1f769be + ef04571 commit 89037db
Show file tree
Hide file tree
Showing 7 changed files with 68 additions and 17 deletions.
56 changes: 49 additions & 7 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,52 @@
1. Add tests for modified or additional code
2. Use a separate branch for development with the following naming convention
# Contributing
---

[type]-[name]
***Use a separate branch for development with the following naming convention***

**Examples:**
```
- bugfix-some-unique-branch-name
- hotfix-some-unique-branch-name
- feature-some-unique-branch-name
```

bugfix-some-unique-branch-name
hotfix-some-unique-branch-name
feature-some-unique-branch-na
1. clone this repo
1. install dependencies (jest for tests) `npm install`
1. create a new branch named `[type]-[name]` (see example below)
1. commit your changes
1. run tests `npm run test`
1. push your branch to the remote repository
1. create a pull request

---

## Run tests

`npm run test`

![img.png](img.png)

---

## Run encryption from command line

`npm run encrypt`

![img_1.png](img_1.png)

---

## Minify

Until I finalize the pipeline, builds are performed manually.

`npm run build`

Please keep the following in mind when developing:

- Add tests for modified or additional code
- Keep code bloat to a minimum, the final minified code should remain very small
- Maintain a consistent style
- Use no dependencies
- Comment everything (see example)

![img_3.png](img_3.png)
27 changes: 18 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,16 @@

[![Node.js Package](https://github.com/w4ffl35/js-ktc/actions/workflows/npm-publish.yml/badge.svg)](https://github.com/w4ffl35/js-ktc/actions/workflows/npm-publish.yml) [![CodeQL](https://github.com/w4ffl35/js-ktc/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/w4ffl35/js-ktc/actions/workflows/codeql-analysis.yml) [![contributions welcome](https://img.shields.io/badge/contributions-welcome-brightgreen.svg?style=flat)](https://github.com/dwyl/esta/issues)

An implementation of a basic keyword transposition cipher in Javascript with no external dependencies.
An implementation of a basic keyword transposition cipher in Javascript with zero dependencies.

✅ Easy to use<br />
✅ Extensible<br />
✅ Test coverage<br />
✅ Lots of comments (good for education)<br />
✅ No bloat (zero dependencies)<br />
✅ MIT license

---

## Installation

Expand All @@ -17,16 +26,16 @@ An implementation of a basic keyword transposition cipher in Javascript with no
- **Encrypt** `ktc.encrypt('CRYPTOLOGY')`
- **Decrypt** `ktc.decrypt('JHQSU XFXBQ')`

## Contributing

---

Please use a separate branch for development with the following naming convention
## Limitations

`[type]-[name]`
The basic implementation only works with A-Z though it can easily be extended to support other characters.

***Examples:***
---

## Development

---

- bugfix-some-unique-branch-name
- hotfix-some-unique-branch-name
- feature-some-unique-branch-name
See the [CONTRIBUTING.md](CONTRIBUTING.md) file for instructions on how to contribute to this project.
Binary file added img.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img_3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "js-ktc",
"version": "1.1.6",
"version": "1.1.7",
"description": "Javascript Keyword Transposition Cipher",
"main": "cipher.min.js",
"scripts": {
Expand Down

0 comments on commit 89037db

Please sign in to comment.