Skip to content

Commit 5234a7d

Browse files
committed
Init
1 parent 41d22ff commit 5234a7d

File tree

8 files changed

+1756
-1
lines changed

8 files changed

+1756
-1
lines changed

.devcontainer/Dockerfile

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
#-------------------------------------------------------------------------------------------------------------
2+
# Copyright (c) Microsoft Corporation. All rights reserved.
3+
# Licensed under the MIT License. See https://go.microsoft.com/fwlink/?linkid=2090316 for license information.
4+
#-------------------------------------------------------------------------------------------------------------
5+
6+
# To fully customize the contents of this image, use the following Dockerfile instead:
7+
# https://github.com/microsoft/vscode-dev-containers/tree/v0.128.0/containers/javascript-node-14/.devcontainer/Dockerfile
8+
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-14
9+
10+
# ** [Optional] Uncomment this section to install additional packages. **
11+
#
12+
# RUN apt-get update \
13+
# && export DEBIAN_FRONTEND=noninteractive \
14+
# && apt-get -y install --no-install-recommends <your-package-list-here>
15+

.devcontainer/devcontainer.json

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// For format details, see https://aka.ms/vscode-remote/devcontainer.json or this file's README at:
2+
// https://github.com/microsoft/vscode-dev-containers/tree/v0.128.0/containers/javascript-node-14
3+
{
4+
"name": "Node.js 14",
5+
"dockerFile": "Dockerfile",
6+
7+
// Set *default* container specific settings.json values on container create.
8+
"settings": {
9+
"terminal.integrated.shell.linux": "/bin/bash"
10+
},
11+
12+
// Add the IDs of extensions you want installed when the container is created.
13+
"extensions": [
14+
"dbaeumer.vscode-eslint"
15+
]
16+
17+
// Use 'forwardPorts' to make a list of ports inside the container available locally.
18+
// "forwardPorts": [],
19+
20+
// Use 'postCreateCommand' to run commands after the container is created.
21+
// "postCreateCommand": "yarn install",
22+
23+
// Uncomment to connect as a non-root user. See https://aka.ms/vscode-remote/containers/non-root.
24+
// "remoteUser": "node"
25+
}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules

README.md

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,49 @@
1-
# boolean
1+
# boolean.js
2+
Function for simplifying boolean expressions. Loosely based on boolean.py from bastikr.
3+
4+
## Install
5+
6+
Will hopefully be soon on npm ...
7+
8+
## Usage
9+
10+
Currently defined tokens:
11+
* '+': AND
12+
* '-': NOT
13+
* '|', '/': OR
14+
* '(': Left bracket
15+
* ')': Right bracket
16+
17+
```
18+
import booljs from "boolean";
19+
console.log(booljs("a+1+b|0");
20+
```
21+
## Open Tasks/Laws
22+
Currently not implemente laws from https://booleanpy.readthedocs.io/en/latest/concepts.html#laws:
23+
* Associativity: x|(y|z) = x|y|z
24+
* Distributivity: x+(y|z) = x+y|x+z, x|y+z = (x|y)+(x|z)
25+
* De-Morgan: -(x|y) = (-x)+(-y)
26+
* Elimination: x+y|x+(-y) = x, (x|y)+(x|(-y)) = x
27+
28+
## License
29+
MIT License
30+
31+
Copyright (c) 2020 bigbug
32+
33+
Permission is hereby granted, free of charge, to any person obtaining a copy
34+
of this software and associated documentation files (the "Software"), to deal
35+
in the Software without restriction, including without limitation the rights
36+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
37+
copies of the Software, and to permit persons to whom the Software is
38+
furnished to do so, subject to the following conditions:
39+
40+
The above copyright notice and this permission notice shall be included in all
41+
copies or substantial portions of the Software.
42+
43+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
44+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
45+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
46+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
47+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
48+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
49+
SOFTWARE.

0 commit comments

Comments
 (0)