This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"rulesDirectory": [ | |
"codelyzer" | |
], | |
"rules": { | |
"align": [true, "statements"], | |
"array-type": [true, "array"], | |
"deprecation": { | |
"severity": "warn" | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Taken from [Angular Deploymenr](https://angular.io/guide/deployment) Guide. | |
# | |
# INSTRUCTIONS: | |
# 1. Place this file next to the app's index.html. | |
# 2. Optional: If you serve your app from a subfolder in your domain, | |
# | |
# Gist forked from: [julianpoemp](https://gist.github.com/julianpoemp/bcf277cb56d2420cc53ec630a04a3566) | |
# Check for new versions of this gist: https://gist.github.com/RaschidJFR/f6d21a03b0692f5c7a6a23954003f00b | |
# v1.1.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
// Use IntelliSense to learn about possible attributes. | |
// Hover to view descriptions of existing attributes. | |
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"type": "node", | |
"request": "attach", | |
"name": "Attach", // Attach to a running node process (with `--inspect` flag) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
// This script uploads automatically a folder's content to an ftp server. | |
// For this gist's latest version check https://gist.github.com/RaschidJFR/d6d072d8d95e3f9b2ebd9729a8031f0b | |
// | |
// 1. Make sure you've installed as devDependencies the packages you'll need: | |
// * [node-flags](https://www.npmjs.com/package/node-flags) (needed) | |
// * [ftp-deploy](https://www.npmjs.com/package/ftp-deploy) (for normal FTP upload) | |
// * [ftp-diff-deployer](https://www.npmjs.com/package/ftp-diff-deployer) (for uploading diffs on normal FTP) | |
// * [sftp-upload](https://www.npmjs.com/package/sftp-upload) (for SFTP) | |
// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Configuration for develpment build on local database | |
module.exports = { | |
ENV: Object.freeze({ | |
prod: false, | |
databaseUrl: 'http://localhost:1337/*******' | |
}) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
Some low-end android devices are too slow thus take too long to load the app, | |
which causes throwing error "can't load index.html". | |
Just add these settings after <preference name="SplashScreen" value="screen" /> in config.xml. | |
--> | |
<preference name="SplashScreenDelay" value="3000" /> | |
<preference name="AutoHideSplashScreen" value="false" /> | |
<preference name="ShowSplashScreenSpinner" value="true" /> | |
<preference name="loadUrlTimeoutValue" value="700000" /> | |
<!-- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
// This script runs a simple server for HTML, CSS, JS files. | |
const publicFolder = 'www'; // Change this folder to point to your web files | |
const port = 8080; // Default port for web server but you can change it | |
// (Make sure you've installed the required dependencies) | |
const express = require('express'); | |
const path = require('path'); | |
const app = express(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
// ## Automatically sign and align apk ## | |
// Just run this script `$ node sign_apk.js` | |
const CONFIG_FILE_NAME = 'sign-apk.json'; | |
const configFileStruct = { | |
"keystorePath": "relative/path/to/file.keystore", | |
"zipalignPath": "C:/Program Files (x86)/Android/android-sdk/build-tools/26.0.2/zipalign", | |
"apkPath": "C:/your-ionic-project-root/platforms/android/build/outputs/apk/android-release-unsigned.apk", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Convert mp3 files recursively to wav using [fluent-ffmpeg](https://github.com/fluent-ffmpeg/node-fluent-ffmpeg) for [node.js](https://nodejs.org) | |
// | |
// 1. Install fluent-ffmpeg: `npm install fluent-ffmpeg` | |
// 2. Run this script: `node mp3ToWav.js [path/to/file/or/folder]` | |
convertMp3ToWav = function (input) { | |
let segments = input.split('/'); | |
let filename = segments[segments.length - 1]; | |
let extension = filename.split('.')[1]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
// This script increments patch number (mayor.minor.patch) but you can | |
// choose to increment any other segment by modifying lines `45` to `53`. | |
// | |
// 1. Make sure you've installed *xml2js*: `$ npm install xml2js -D` | |
// 2. Save this file under `project_root/hooks/before_prepare/` | |
// 3. Done! | |
var fs = require('fs'); | |
var xml2js = require('xml2js'); |
NewerOlder