Giter Site home page Giter Site logo

kagrenac's Introduction

Version CircleCI [Appveyor CI] Codecov Downloads License

Kagrenac

Lord Kagrenac was the Dwemeri Chief Tonal Architect during the time of the First Council. The foremost arcane philosopher and magecrafter of the Dwemer, he was a "pioneer" in the field of mythopoeic forces, and devised tools with which to harness them with the intent of transcending the limits of Dwemer mortality.

About

Kagrenac is CLI tool to aid in developing and publishing Elder Scrolls® Online add-ons on ESOUI.

Usage

$ npm install -g kagrenac
$ kag COMMAND
running command...
$ kag (-v|--version|version)
kagrenac/0.1.0 linux-x64 node-v11.8.0
$ kag --help [COMMAND]
USAGE
  $ kag COMMAND
...

Commands

kag create TITLE

create new add-on from a template

USAGE
  $ kag create TITLE

ARGUMENTS
  TITLE  add-on name that will be displayed in game

OPTIONS
  -a, --api=api                  [default: 100026] interface version the add-on is compatible with
  -d, --description=description  description of the add-on
  -h, --help                     show CLI help
  -n, --name=name                name of the add-on

  -p, --path=path                (required) [default: /home/arthur/Documents/Elder Scrolls Online/live/AddOns] where the
                                 add-on will be created

  -t, --template=template        (required) [default: standalone] name of built-in template or path to your own

  -u, --author=author            [default: Your Name] author of the add-on

  -v, --variables=variables      space separated name of saved variables

EXAMPLE
  $ kagrenac create

See code: src/commands/create.ts

kag help [COMMAND]

display help for kag

USAGE
  $ kag help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI

See code: @oclif/plugin-help

Legal

The MIT License © 2019 ESOUI Community.

This project is not created by, affiliated with, or sponsored by ZeniMax Media Inc. or its affiliates. The Elder Scrolls® and related logos are registered trademarks or trademarks of ZeniMax Media Inc. in the United States and/or other countries. All rights reserved. The usage of add-ons is governed by the Add-on Terms of Use.

kagrenac's People

Contributors

haggen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

rodrigo54

kagrenac's Issues

esoui api support

Kagrenac should be able to automatically upload addons via the ESOUI Update API. The necessary information should be saved in meta files or the settings as described in #3.

"build" addons

My projects reside outside the addon folder, so in order to test them I have to copy all files there. This would of course be a tedious task to do by hand, so I have created a script that allows me to build "development" and "release" versions of my addons. Development builds will replace tokens in my manifest and Lua files with one set of values and then copy the addon to the live folder. Release builds use a different set of values and automatically create a zip file with a name based on the addon version in a target folder. I'm also playing with the thought of updating my script so it uses semantic versioning for the human readable "Version" and a build number for the "AddOnVersion".

The question is how much of this should be done directly by Kargrenac. There are already plenty of build systems like gulp or ant, which can handle most of the necessary steps. Maybe kagrenac should only expose knowledge about ESO addons and let other tools handle the rest? Like which folder to copy the addon to (pts, live) or a standardized list of tokens to use.

Either way, I'll be happy as long as it runs the copy task extremely fast. I once tried to port my build script from ant to gradle for fun, but the execution speed was horrible, so I went back to ant.

addon validation

There are many things that would be interesting to validate when creating a release build.

  • Manifest file for missing directives (author, addon version, api version, etc) or incorrect information (typos, non-existing files, unused lua/xml files in the addon folder)
  • Static code analysis of lua and xml files via SonarQube
  • xml schema validation.
  • Addon Dependencies (check if there are newer versions than last time that should be reviewed)
  • Leaked globals (there is already a tool, but it uses powershell which limits it to windows)
  • Use of removed APIs after an update (could make use of esoui-doc-converter).

create new addon from template

In my local build environment I use an ant script to create new projects from templates. It asks if I want to create an addon or library, copies the files from the appropriate template folder, renames the manifest.txt to match the addon name and finally replaces the tokens in all files.

A better way would be to allow tokens in filenames too, instead of having any special files.

Kagrenac should follow the following procedure:

  1. Check a folder which is supposed to contain the templates. This folder comes with a few predefined templates (blank, addon, library), but the user can also add custom templates.
  • The blank template would just be a minimal example of what is needed to run code.
  • "Addon" could contain some utility functions and patterns that are often used (e.g. global namespace variable + multiple files, LAM settings panel, logging facilities)
  • "Library" would do the same, just for a project that should be considered a library.
  1. Show the user a list of all of them to choose from.
  2. Ask the user what the addon title, author name, api version, addon version etc should be.
  3. Copy the template to the target folder and replace tokens in all filenames and files.

The whole process could look like this:

>kagrenac create MyAddon
Please select a template:
1. Blank - A minimal addon with only the bare necessities
2. Addon - A template with everything addons regularly need
3. Library - A template specifically for libraries
4. MySuperDuperTemplate - Has all the secret sauce
>4
What should the addon be called? ("MyAddon")
>
Who is the author? ("sirinsidiator")
>
Which API versions should it support? (100026)
>100026 100027
What Version should it start with? (1.0.0)
>0.0.1
What AddOnVersion should it start with? (1)
> 100
Creating "MyAddon"... done

unit testing

When building an addon (#2) it could be nice to also run a set of unit tests using the busted framework. The templates in #1 could contain an example of how to define unit tests and mock the eso api and lua code.

local settings

Kagrenac should be able to store some settings and offer a command to let users change them. There are three sets of information that need to be stored: machine setings, user settings and addon settings.

Machine settings would allow to overwrite the path to the eso user folder or executables that may be used by kagrenac. The user settings would contain information like the author name or the ESOUI api token. Addon settings would be specific to each addon and contain the id used on esoui and other things that are used when updating addons (addon information, images, change log, version, compatibility, etc).

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.