GithubHelp home page GithubHelp logo

nandomoreirame / autoamazing Goto Github PK

View Code? Open in Web Editor NEW
5.0 1.0 1.0 493 KB

:tropical_drink: Automatizate amazing tasks for front-end with Gulpjs

Home Page: https://www.npmjs.com/package/autoamazing

License: MIT License

JavaScript 99.94% CSS 0.06%
gulp gulpjs tasks task-runner sass javascript css html pug

autoamazing's Introduction



autoamazing

Build Status Coverage Status Code Climate Issue Count

🍹 Automatizate amazing tasks for front-end with Gulpjs


⚠️ This repository is still under development

Installation

$ npm install --save-dev autoamazing

Usage

const gulp = require('gulp')
const task = require('autoamazing')
const gutil = require('gulp-util')

const env = gutil.env.env || 'development'

task.clean(gulp, {
  taskname: 'clean',
  src: [
    `dist/*`,
    `!dist/images`
  ]
})

task.stylesheets(gulp, {
  taskname: 'sass',
  src: 'src/sass/main.sass',
  dest: 'dist/css',
  env: env
})

task.stylesheets(gulp, {
  taskname: 'css',
  src: 'dist/css/main.css',
  dest: 'dist/css',
  env: env,
  sass: false
})

task.scripts(gulp, {
  src: [
    `src/javascripts/*.js`,
    `src/javascripts/vendor/*.js`
  ],
  dest: `dist/javascripts`,
  env: env,
  include: true,
  includeSettings: {
    extensions: 'js',
    includePaths: [
      `node_modules`,
      `src/javascripts`
    ]
  }
})

task.scripts(gulp, {
  taskname: 'js:babel',
  src: 'samples/input/main-babel.js',
  dest: 'samples/output',
  env: env,
  babel: true
})

task.scripts(gulp, {
  taskname: 'js:webpack',
  src: 'samples/input/main-webpack.js',
  dest: 'samples/output',
  env: env,
  sourcemaps: false,
  webpack: true,
  webpackConfig: {
    entry: path.resolve(__dirname, `samples/input/main-webpack.js`),
    output: {
      path: path.resolve(__dirname, `./samples/output/`)
    }
  }
})

task.eslint(gulp, {
  src: [
    `src/javascripts/**/*.js`,
  ]
})

task.copy(gulp, {
  taskname: 'fonts',
  src: [
    `node_modules/font-awesome/fonts/*`,
    `src/fonts/*`
  ],
  dest: `dist/fonts`
})

task.images(gulp, {
  src: `dist/images/**/*`,
  dest: `dist/images`,
  env: env,
  imageSettings: {
    pngquant: true,
    optipng: true,
    zopflipng: true,
    advpng: true,
    jpegRecompress: false,
    jpegoptim: true,
    mozjpeg: true,
    gifsicle: true,
    svgo: true
  }
})

On your terminal execute: gulp --tasks

License

MIT © Fernando Moreira

autoamazing's People

Contributors

itsjw avatar nandomoreirame avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

itsjw

autoamazing's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.