Skip to content

Instantly share code, notes, and snippets.

View umarmw's full-sized avatar

Umar Waliyullah umarmw

View GitHub Profile
#!/bin/bash
#
# Copyright IBM Corp All Rights Reserved
#
# SPDX-License-Identifier: Apache-2.0
#
# Exit on first error
set -e
# don't rewrite paths for Windows Git Bash users
@umarmw
umarmw / webpack-config.js
Created May 25, 2018 11:30
webpack-config
//ref: https://getbootstrap.com/docs/4.0/getting-started/webpack/
const config = require("./gulp-config.js")();
const path = require("path");
const webpack = require("webpack");
const CopyWebpackPlugin = require("copy-webpack-plugin");
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
const currentDir = path.resolve();
let WPconfig = {
@umarmw
umarmw / app.js
Last active December 13, 2017 12:01
contact form with express js example
var express = require('express');
var Webtask = require('webtask-tools');
var bodyParser = require('body-parser');
var app = express();
app.use(bodyParser.json());
app.use(bodyParser.urlencoded({ extended: true }));
app.get('/', function (req, res) {

Info

I came across this file after the Hosting provider told me that my server IP was backlisted due to this. Anybody can help with this?

@umarmw
umarmw / assertions-compareScreenshot.js
Last active May 20, 2019 11:29 — forked from richard-flosi/assertions-compareScreenshot.js
Nightwatch with Visual Regression testing
// location: ./assertions/compareScreenshot.js
var resemblejs = require('node-resemble-js'),
fs = require('fs');
exports.assertion = function(filename, expected) {
var screenshotPath = 'test/screenshots/',
baselinePath = screenshotPath + 'baseline/' + filename,
resultPath = screenshotPath + 'results/' + filename,
diffPath = screenshotPath + 'diffs/' + filename;