Skip to content
This repository has been archived by the owner on Aug 9, 2020. It is now read-only.

SerafimArts/HaxeWatcher

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Haxe PHP Watcher

Requirements

  1. PHP >= 7.4
  2. Haxe Compiler (for local development only)
  3. Composer

Installation

  • composer require serafim/haxe-watcher

Configuration

Configuration using extra section in your composer.json file:

{
    "extra": {
        "haxe": {
            // Path to Haxe Compiler.
            //  - Information from the PATH environment variable 
            //    is read by default ("haxe" binary).
            "compiler": "/usr/bin/haxe",

            // Path to source files.
            //  - Information from the "autoload" (psr-0, psr-4, classmap) 
            //    section is read by default.
            "src": [
                "path/to/sources"
            ],
    
            // Number of milliseconds to check file updates.
            //  - 60000 by default
            "watch": 60000,
    
            // The name of the configuration file generated for 
            // the Haxe Compiler.
            //  - "build.hxml" by default
            "config": "test.hxml"
        }
    }
}

Usage

Haxe Compiler Version

$ composer haxe:version

Run Haxe Watcher

$ composer haxe:watch

Example

Project Structure

- app/
    - Main.hx
- composer.json

Instruction

  1. Create composer.json with following code
{
    "require": {
        "serafim/haxe-watcher": "*"
    },
    "autoload": {
        "psr-4": {
            "app": "app"
        }
    },
    "minimum-stability": "dev",
    "prefer-stable": true
}
  1. Create app/Main.hx with following code:

Main.hx File

module app;

class Main {
    static function main() {
        Sys.println("test");
    }
}
  1. Run watcher: composer haxe:watch

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages