Commit 8bc6c624 authored by kosheo's avatar kosheo

Update CI script. Add GitLab logo and update links.

parent e111393e
Pipeline #23589120 passed with stages
in 5 minutes and 6 seconds
node_modules/
dist/
public/
coverage/
package-lock.json
......@@ -3,14 +3,10 @@ image: node:8
stages:
- build
- test
- deploy
cache:
paths:
- node_modules/
before_script:
- node_modules
build:
stage: build
......@@ -19,7 +15,7 @@ build:
- npm run dist
artifacts:
paths:
- dist/
- public
lint:
stage: test
......@@ -40,14 +36,3 @@ test:
- npm test
- lcov --summary coverage/Firefox*/lcov.info
coverage: '/lines......:\s*(\d+.\d+\%)/'
pages:
stage: deploy
script:
- mkdir public
- cp -r dist/* public
artifacts:
paths:
- public
only:
- master
https://clcalc.net
[![Build Status](https://travis-ci.org/ovk/clcalc.svg?branch=master)](https://travis-ci.org/ovk/clcalc)
[![Coverage Status](https://coveralls.io/repos/github/ovk/clcalc/badge.svg?branch=master)](https://coveralls.io/github/ovk/clcalc?branch=master)
[![Maintenance](https://img.shields.io/maintenance/yes/2018.svg)]()
[![license](https://img.shields.io/github/license/ovk/clcalc.svg)]()
[![pipeline status](https://gitlab.com/thealik/clcalc/badges/master/pipeline.svg)](https://gitlab.com/thealik/clcalc/commits/master)
[![coverage report](https://gitlab.com/thealik/clcalc/badges/master/coverage.svg)](https://gitlab.com/thealik/clcalc/commits/master)
# Summary
Cl Calc is an open-source, lightweight, command-line style online calculator. It is built as fully static website and hosted through GitHub Pages (`docs` directory in the repository contains actual website). As the result of being completely static, Cl Calc performs all calculations on the client side.
Cl Calc is an open-source, lightweight, command-line style online calculator. It is built as fully static website and hosted through GitLab Pages. As the result of being completely static, Cl Calc performs all calculations on the client side.
Cl Calc uses [MathJS](http://mathjs.org) library for expression parsing and evaluation; thus, all MathJS features are available in Cl Calc.
......@@ -28,9 +26,9 @@ If you are completely new to Cl Calc you may want to check this small [Quick Sta
# Build
Get the sources from the GitHub:
Get the sources from the GitLab:
```
git clone https://github.com/ovk/clcalc.git
git clone https://gitlab.com/thealik/clcalc.git
cd clcalc
```
......@@ -43,13 +41,13 @@ To build the production version of the Cl Calc website:
```
npm run dist
```
This will create `dist` directory with generated HTML, CSS, JavaScript files and images.
This will create `public` directory with generated HTML, CSS, JavaScript files and images.
For development build do:
```
npm run dev
```
In development build `dist` directory will also contain source maps for JavaScript files and HTML files won't be minified. In addition to that, a web server will be started hosting `dist` contents at http://localhost:8080. It watches for changes and automatically re-runs necessary tasks to regenerate HTML, CSS or JavaScript as needed.
In development build `public` directory will also contain source maps for JavaScript files and HTML files won't be minified. In addition to that, a web server will be started hosting `public` contents at http://localhost:8080. It watches for changes and automatically re-runs necessary tasks to regenerate HTML, CSS or JavaScript as needed.
# Test
......@@ -70,4 +68,4 @@ This will also generate code coverage data available under `coverage` directory.
# License
Cl Calc is licensed under [MIT](https://github.com/ovk/clcalc/blob/master/LICENSE) license.
Cl Calc is licensed under [MIT](https://gitlab.com/thealik/clcalc/blob/master/LICENSE) license.
clcalc.net
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1"><meta name="description" content="Advanced online command-line style calculator with mathematical, scientific, programming, utility functions and more"><title>Cl Calc: Online Command-Line Calculator</title><link href="favicon.ico" rel="shortcut icon"><link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha256-916EbMg70RQy9LHiGkXzG8hSg9EdNy97GazNG/aiY1w=" rel="stylesheet" type="text/css" crossorigin="anonymous"><link href="https://fonts.googleapis.com/css?family=Roboto+Mono:400,400i,700" rel="stylesheet" type="text/css"><script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha256-U5ZEeKfGNOja007MMD3YBI0A3OSZOQbeG6z2f2Y0hu8=" crossorigin="anonymous"></script><link href="https://cdnjs.cloudflare.com/ajax/libs/jquery.terminal/1.14.0/css/jquery.terminal.min.css" integrity="sha256-mq1+xllyX0rV8IK7kgMffZp2PZzBWB1+ZNdnhB338O8=" rel="stylesheet" type="text/css" crossorigin="anonymous"><link href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.9.0/katex.min.css" integrity="sha256-uXNHy6FK52Pb83SmU45mVAg7YECmr9Lwwu1zOz31j5c=" rel="stylesheet" type="text/css" crossorigin="anonymous"><!-- Create link (expression or log) popower template--><script type="text/html" id="template-create-link-popover"><div class="input-group"><input class="form-control" type="text" readonly="true" value="{link}"><span class="input-group-btn"><button class="btn btn-primary copy-link-to-clipboard" type="button"><span class="glyphicon glyphicon-copy"></span>&nbsp;Copy</button></span></div></script><!-- Create link (expression or log) popower template without 'Copy' button--><script type="text/html" id="template-create-link-popover-no-copy"><input class="form-control" type="text" readonly="true" value="{link}"></script><!-- Create expression link button template--><script type="text/html" id="template-create-expression-link-button"><div style="float: right"><a class="create-expression-link-button" href="javascript:void(0)" role="button"><span class="glyphicon glyphicon-link"></span></a></div></script><link href="main.css" rel="stylesheet" type="text/css"></head><body><nav class="navbar navbar-default navbar-fixed-top"><div class="container-fluid"><div class="navbar-header"><a class="navbar-brand" href="/"><img alt="Cl Calc" src="./brand.png" width="20" height="20">Cl Calc</a></div><div><ul class="nav navbar-nav navbar-right"><li> <a href="https://github.com/ovk/clcalc"> <img alt="GitHub Page" src="./github.png" width="20" height="20">GitHub</a></li></ul></div></div></nav><div class="modal fade" id="settings-dialog" tabindex="-1"><div class="modal-dialog"><div class="modal-content"><div class="modal-header"><button class="close" type="button" data-dismiss="modal"><span>&times;</span></button><h4 class="modal-title">Settings</h4></div><div class="modal-body"><form class="form-horizontal"><div class="form-group"><label class="col-sm-6 control-label">Thousands Separator:</label><div class="col-sm-6"><select class="form-control"><option value="enabled">Enabled</option><option value="disabled">Disabled</option></select></div></div><div class="form-group"><label class="col-sm-6 control-label">Precision (Significant Digits):</label><div class="col-sm-6"><input class="form-control" type="text"></div></div></form></div><div class="modal-footer"><button class="btn btn-default" type="button" data-dismiss="modal">Close</button><button class="btn btn-primary" type="button">Apply</button></div></div></div></div><div class="sidebar"><a href="javascript:void(0)" id="generate-log-link-button"><div class="round-button" title="Create link with the current calculator content" data-toggle="tooltip" data-placement="bottom" data-container="body" data-delay="{ &quot;show&quot;: 800, &quot;hide&quot;: 100 }"><span class="glyphicon glyphicon-link"></span></div></a><a href="javascript:void(0)" id="toggle-tex-panel-button"><div class="round-button" title="Toggle TeX panel" data-toggle="tooltip" data-placement="bottom" data-container="body" data-delay="{ &quot;show&quot;: 800, &quot;hide&quot;: 100 }"><span class="glyphicon glyphicon-text-size"></span></div></a><a href="javascript:void(0)" id="show-settings-dialog-button"><div class="round-button" title="Show settings dialog" data-toggle="tooltip" data-placement="bottom" data-container="body" data-delay="{ &quot;show&quot;: 800, &quot;hide&quot;: 100 }"><span class="glyphicon glyphicon-wrench"></span></div></a><a href="/help.html" target="_blank"><div class="round-button" title="Open help page" data-toggle="tooltip" data-placement="bottom" data-container="body" data-delay="{ &quot;show&quot;: 800, &quot;hide&quot;: 100 }"><span class="texticon">?</span></div></a></div><div class="content-panel"><div class="content-wrapper"><div class="console-wrapper"><div class="console-wrapper-inner"><div class="console-panel"></div></div></div><div class="tex-wrapper"><div class="tex-wrapper-inner"><div class="tex-panel"></div></div></div></div></div><script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-mousewheel/3.1.13/jquery.mousewheel.min.js" integrity="sha256-jnOjDTXIPqall8M0MyTSt98JetJuZ7Yu+1Jm7hLTF7U=" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.terminal/1.14.0/js/jquery.terminal.min.js" integrity="sha256-ToGKit0KiJNw/mnWsx1diPiHLKU03nSg5Q9KA1YreIM=" crossorigin="anonymous"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/mathjs/4.2.2/math.min.js" integrity="sha256-tRhxv5eS1muRWknKkTRbDbTU//s8NKodXWwq1uADPww=" crossorigin="anonymous"></script><script src="calc.js"></script></body></html>
\ No newline at end of file
.navbar{margin-bottom:0;border-radius:0}@media (max-width:767px){.navbar{min-height:32px}}.navbar-header{float:left}@media (max-width:767px){.navbar-brand{padding:6px;height:32px}}.navbar-brand>img{display:inline-block;vertical-align:top;margin-right:4px}.navbar-right{float:right}.navbar-right img{vertical-align:top;margin-right:4px;opacity:.7}.navbar-nav{margin-top:0;margin-bottom:0}.navbar-nav>li>a{padding:15px}@media (max-width:767px){.navbar-nav>li>a{padding:6px}}.content-panel{position:fixed;top:50px;bottom:0;left:50px;right:0}@media (max-width:767px){.content-panel{top:72px;left:0}}.content-wrapper{display:table;width:100%;height:100%}.console-wrapper{display:table-cell;position:relative;width:65%;height:100%}@media (max-width:767px){.console-wrapper{display:table-row;position:static;width:100%;height:65%}}.console-wrapper-inner{width:100%;height:100%}@media (max-width:767px){.console-wrapper-inner{display:table-cell;position:relative;height:auto}}.tex-wrapper{display:none;position:relative;height:100%;border-left:1px solid #d7d7d7}@media (max-width:767px){.tex-wrapper{display:none;position:static;width:100%;height:auto;border-left:none}}.tex-wrapper-inner{width:100%;height:100%}@media (max-width:767px){.tex-wrapper-inner{display:table-cell;position:relative;height:auto;border-top:1px solid #d7d7d7}}.popover-title{font-weight:700}.sidebar{position:fixed;top:50px;bottom:0;left:0;width:50px;border-right:1px solid #d7d7d7;background-color:#e7e7e7}@media (max-width:767px){.sidebar{top:32px;bottom:auto;right:0;width:auto;height:40px;border-right:none;border-bottom:1px solid #d7d7d7}}.sidebar>a{color:#777;font-size:16px;line-height:20px;text-decoration:none;outline:0}.sidebar>a>.round-button{position:relative;width:34px;height:34px;margin-top:12px;margin-bottom:0;margin-left:auto;margin-right:auto;border-radius:50%;transition:background-color .2s ease 0s;background-color:#d8d8d8}@media (max-width:767px){.sidebar>a>.round-button{display:inline-block;margin-top:3px;margin-bottom:3px;margin-left:4px;margin-right:0}}.sidebar>a>.round-button:hover{background-color:#c7c7c7}.sidebar>a>.round-button span{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.sidebar>a>.round-button span.texticon{font-size:18px;font-weight:700}.sidebar>a.active>.round-button{background-color:#c7c7c7}.sidebar>a.disabled>.round-button{cursor:not-allowed;color:#afafaf;background-color:#e2e2e2}.cmd,.terminal{font-family:'Roboto Mono',monospace;color:#7a9983;background-color:#fdfdfd}.cmd,.cmd .prompt,.terminal .terminal-output div div{font-size:16px;line-height:24px}.cmd{margin-top:4px}.terminal{position:absolute;top:0;bottom:0;left:0;right:0;padding:12px;margin:0}.terminal .terminal-output .command{margin-top:4px}.terminal .terminal-output .welcome-message{color:#7a9983;padding-bottom:16px;font-style:italic;opacity:.7;word-break:normal}.terminal .terminal-output .ts{padding-right:.25em}.terminal .terminal-output-error{color:#fa5050;padding-left:12px}.terminal a:hover{background:0 0;text-decoration:underline;color:#0f60ff}.terminal .command.active{background-color:#eff5ef;border-radius:4px}.terminal .create-expression-link-button{color:#9f9f9f;text-decoration:none;outline:0;transition:color .2s ease 0s}.terminal .create-expression-link-button:hover{color:#777}.terminal .prompt-wrapper{width:12px}.terminal .raw{padding-left:12px;color:#66b734}.terminal .raw div{word-break:break-all}@keyframes terminal-blink{0%,100%{color:#f0f0f0;background-color:#909090}50%{color:#777;background-color:#ccc}}.highlight-constant{font-style:italic}.highlight-keyword{font-weight:700}.highlight-color{font-weight:700}.terminal .terminal-output div div .color-sample{display:inline-block;height:24px;width:24px;border-radius:4px;background:url(checkerboard.png) no-repeat left top;background-size:cover;cursor:pointer}.terminal .terminal-output div div .color-sample div{border-radius:4px}.function-plot2d-event-grab{cursor:crosshair;pointer-events:all}.function-plot2d-legend{font-family:'Roboto Mono',monospace;font-size:10px;fill:#999}.function-plot2d-axis-x,.function-plot2d-axis-y{stroke:#aaa}.function-plot2d-axis-x text,.function-plot2d-axis-y text{fill:#999;font-weight:400;font-size:11px;stroke-width:0}.function-plot2d-origin-x,.function-plot2d-origin-y{stroke:#ccc}.function-plot2d-graph{stroke:#0dc1e5}.tex-panel{position:absolute;top:0;bottom:0;left:0;right:0;padding:0;margin:0;overflow-y:auto;background-color:#f7f7f7}.tex-panel>.tex-block{border:1px solid #eee;border-radius:2px;background-color:#fdfdfd;margin:8px;padding:8px;overflow-x:auto}.tex-panel>.tex-block .tex-expression{margin:8px}.tex-panel>.tex-block .tex-value{margin-left:8px;margin-right:8px;margin-bottom:8px;padding-top:8px;border-top:1px solid #eee}body{margin-top:50px}@media (max-width:767px){body{margin-top:32px}}.help-container{padding-top:50px;margin-top:-50px;font-family:Lato,"Helvetica Neue",Helvetica,Arial,sans-serif}.help-toc{position:fixed;top:70px}.help-toc ul{list-style-type:none;padding-left:20px}.help-toc ul li{font-size:13px;line-height:22px}@media (max-width:991px){.help-toc{position:static}}.help-content{font-size:16px}.help-content h1,.help-content h2{padding-top:50px;margin-top:-50px}.help-content h1{color:#0e83cd;border-bottom:1px solid #ddd;padding-bottom:5px;margin-bottom:20px;margin-top:-30px}.help-content h2{color:#0e83cd;font-size:24px;margin-top:-35px}.help-content table{font-size:14px}.help-content table td.code{font-family:'Roboto Mono',monospace}code{font-family:'Roboto Mono',monospace;font-size:16px;line-height:24px;color:#7a9983;background-color:#f5f5f5;display:block;margin-top:0;margin-bottom:12px;margin-left:8px;margin-right:8px;padding-top:4px;padding-bottom:4px;padding-left:0;padding-right:0;word-break:break-all}code span.expr{display:block;margin-left:8px}code span.expr::before{content:'>';display:inline-block;width:16px}code span.value{margin-left:24px;margin-bottom:4px;color:#66b734}code .help-try-it{display:inline-block;float:right;border-top-left-radius:0;border-top-right-radius:4px;border-bottom-left-radius:4px;border-bottom-right-radius:0;padding-top:2px;padding-bottom:2px;padding-left:6px;padding-right:6px;margin-top:-4px;font-size:14px;color:#fefefe;background-color:#337ab7;outline:0}code .help-try-it:hover{text-decoration:none;background-color:#286090;outline:0}code .help-try-it:focus{text-decoration:none;outline:0}code p{margin:8px}
\ No newline at end of file
User-agent: *
Disallow:
Sitemap: https://clcalc.net/sitemap.xml
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<url>
<loc>https://clcalc.net/</loc>
<lastmod>2017-12-23</lastmod>
<priority>1.00</priority>
<changefreq>weekly</changefreq>
</url>
<url>
<loc>https://clcalc.net/help.html</loc>
<lastmod>2017-12-23</lastmod>
<priority>0.80</priority>
<changefreq>weekly</changefreq>
</url>
</urlset>
......@@ -10,14 +10,14 @@ var gulp = require('gulp'),
sourcemaps = require('gulp-sourcemaps'),
eslint = require('gulp-eslint'),
dev = false,
OUTPUT_DIR = './dist';
OUTPUT_DIR = './public';
/**
* Copy static assets to the output folder.
*/
gulp.task('assets', function ()
{
return gulp.src([ './images/favicon.ico', './images/brand.png', './images/github.png', './images/checkerboard.png' ])
return gulp.src([ './images/favicon.ico', './images/brand.png', './images/gitlab.png', './images/checkerboard.png' ])
.pipe(gulp.dest(OUTPUT_DIR));
});
......
......@@ -101,7 +101,7 @@ block content
p Cl Calc is written purely in JavaScript and it evaluates all expressions directly in your browser. This means that your data is never sent to the server for processing or storage.
p Cl Calc is completely open-source (source is available on #[a(href = 'https://github.com/ovk/clcalc') GitHub]) and licensed under MIT license. It is hosted in transparent manner through GitHub Pages.
p Cl Calc is completely open-source (source is available on #[a(href = 'https://gitlab.com/thealik/clcalc') GitLab]) and licensed under MIT license. It is hosted in transparent manner through GitHub Pages.
p #[strong DISCLAIMER:] Since Cl Calc uses floating-point arithmetic rounding errors and other errors that lead to precision loss are inevitable. Never use Cl Calc for scientific, financial and any other calculations that need precise results. Also remember that as any software product Cl Calc and libraries it uses may have bugs and may produce incorrect results. Always double-check your calculations using multiple tools.
......@@ -709,9 +709,9 @@ block content
// About
h1(id = 'about') About
p Cl Calc is licensed under #[a(href = 'https://github.com/ovk/clcalc/blob/master/LICENSE') MIT] license and its source code is available on the #[a(href = 'https://github.com/ovk/clcalc') GitHub].
p Cl Calc is licensed under #[a(href = 'https://gitlab.com/thealik/clcalc/blob/master/LICENSE') MIT] license and its source code is available on the #[a(href = 'https://gitlab.com/thealik/clcalc') GitLab].
p For contributing, reporting bugs or suggesting features please visit #[a(href = 'https://github.com/ovk/clcalc/issues') issues] page.
p For contributing, reporting bugs or suggesting features please visit #[a(href = 'https://gitlab.com/thealik/clcalc/issues') issues] page.
p Current version: #{version}.
......
......@@ -19,7 +19,7 @@ html(lang = 'en')
script(src = lib.bootstrap.js.url, integrity = lib.bootstrap.js.integrity, crossorigin = 'anonymous')
block inject_head
link(href = 'main.css', rel = 'stylesheet', type = 'text/css')
body
......@@ -31,9 +31,9 @@ html(lang = 'en')
| Cl Calc
div
ul.nav.navbar-nav.navbar-right
li(class = (page === 'help') ? 'active' : '')
a(href = 'https://github.com/ovk/clcalc')
img(alt = 'GitHub Page', src = './github.png', width = 20, height = 20)
| GitHub
li(class = (page === 'help') ? 'active' : '')
a(href = 'https://gitlab.com/thealik/clcalc')
img(alt = 'GitLab Page', src = './gitlab.png', width = 20, height = 20)
| GitLab
block content
block scripts
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment