4.0.1 • Published 2 years ago

lifterlms-lib-tasks v4.0.1

Weekly downloads
77
License
GPL-2.0
Repository
github
Last release
2 years ago

lifterlms-lib-tasks

Gulp tasks and Node utilities for LifterLMS and LifterLMS add-on development

Installation

npm install --save-dev lifterlms-lib-tasks

Create a gulpfile in the root of your project (gulpfile.js)

The file must contain, at a minimum:

var gulp = require('gulp');

require( 'lifterlms-lib-tasks' )( gulp );

Config File

Create a file named .llmsconfig in the root directory of your project

Example:

{
  "build": {
    "custom": [ "custom_build_task_1", "custom_build_task_2" ]
  },
  "pot": {
    "bugReport": "https://mybugreports.tld",
    "domain": "my-text-domain",
    "dest": "i18n/",
    "jsClassname": "LLMS_SLUG_l10n",
    "jsFilename": "class-llms-slug-l10n.php",
    "jsSince": "1.0.0",
    "lastTranslator": "Jeffrey Lebowski <thedude@earthlink.com>",
    "team": "Team Name <team@myteam.com>",
    "package": "my-package-name",
  },
  "scripts": {
    "src": [ "assets/js/\*\*/\*.js", "!assets/js/\*\*/\*.min.js" ],
    "dest": "assets/js/"
  },
  "watch": {
    "custom": [
      {
        "glob": [ "path/to/files/**.js" ],
        "tasks": [ "watch_task_1", "watch_task_2" ]
      }
    ],
  }
}

Tasks

  • gulp build : Run textdomain, pot, scripts, and styles tasks.
  • gulp pot : Generates a .pot file in the configured destination directory (defaults to i18n)
  • gulp scripts : Minifies unminified scripts in the configured scripts.src glob via uglifyjs and saves them with a .min suffix in the scripts.dest directory
  • gulp styles : Compiles .scss files to .css (both minified and unminified) from the configured styles.src glob via gulp-sass and saves in the styles.dest directory.
  • gulp textdomain : Ensures all WP i18n functions have the text domain specified by pot.domain.
  • gulp versioner -V X.X.X : Replaces all instances of "@deprecated version", "@since version", & "@version version" with the supplied version number in specifed files. Uses versioner.src glob. If versioner.scripts is true, adds glob defined in scripts.src.
  • gulp watch : Watch all configured src directories for pot, scripts, and styles tasks and re-run them on change.
4.0.1

2 years ago

4.0.0

2 years ago

3.7.0

4 years ago

3.6.2

4 years ago

3.6.1

4 years ago

3.6.0

5 years ago

3.5.1

5 years ago

3.5.0

5 years ago

3.4.1

5 years ago

3.4.0

5 years ago

3.3.0

5 years ago

3.2.0

5 years ago

3.1.2

5 years ago

3.1.1

5 years ago

3.1.0

5 years ago

3.0.9

5 years ago

3.0.8

5 years ago

3.0.7

5 years ago

3.0.6

5 years ago

3.0.5

6 years ago

3.0.4

6 years ago

3.0.3

6 years ago

3.0.2

6 years ago

3.0.1

6 years ago

3.0.0

6 years ago

2.2.5

6 years ago

2.2.4

6 years ago

2.2.3

6 years ago

2.2.2

6 years ago

2.2.1

6 years ago

2.2.0

6 years ago

2.1.5

6 years ago

2.1.4

6 years ago

2.1.3

6 years ago

2.1.2

6 years ago

2.1.1

6 years ago

2.1.0

6 years ago

2.0.6

6 years ago

2.0.5

6 years ago

2.0.4

6 years ago

2.0.3

6 years ago

2.0.2

6 years ago

2.0.1

6 years ago

2.0.0

6 years ago

1.10.0

6 years ago

1.9.1

6 years ago

1.9.0

6 years ago

1.8.4

6 years ago

1.8.3

6 years ago

1.8.2

6 years ago

1.8.1

6 years ago

1.8.0

6 years ago

1.7.1

7 years ago

1.7.0

7 years ago

1.6.1

7 years ago

1.6.0

7 years ago

1.5.0

7 years ago

1.4.3

7 years ago

1.4.2

7 years ago

1.4.1

7 years ago

1.4.0

7 years ago

1.3.1

7 years ago

1.3.0

7 years ago

1.2.2

7 years ago

1.2.1

7 years ago

1.2.0

7 years ago

1.1.0

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago