npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@typinghare/omake

v1.0.3

Published

A simple build automation tool for OCaml projects.

Downloads

3

Readme

OMake

OMake is a simple build automation tool designed to simplify the process of compiling and executing OCaml projects.

Install

Prerequisites

Before installing OMake, you must have Node.js installed on your system. Node.js is a crucial component as it provides the runtime environment for OMake. There are already many tutorials for installing Node.js online.

If you are a macOS user, I recommend you installing Node.js using Homebrew.

Install OMake with NPM

To install OMake, open your terminal and run the following command:

npm install -g @typinghare/omake

This command installs OMake globally on your system, allowing you to use it in any project.

Verifying the Installation

After installation, you can verify that OMake is correctly installed by checking its version:

omake --version

If OMake is installed properly, this command will display the version number.

Set up your project

Create a Configuration File

OMake uses a configuration file named OMake.ini to understand how to build and run your project. Here's how to set it up:

In the root directory of your project, create a file named OMake.ini, inside which specify the build instructions for your project. For example, to compile an OCaml file named hello.ml, your OMake.ini should look like this:

hello = . hello.ml

Write Your Source Code

In the same directory where your OMake.ini is located, create a new file named hello.ml. Write or paste your source code into hello.ml. For a simple OCaml program that prints "Hello world!", use the following code:

print_string "Hello world!";;

Running Your Project

With the configuration file and source code in place, you can now run your project using OMake:

omake hello

This command tells OMake to execute the build instructions defined in OMake.ini for the hello target, resulting in the compilation and execution of your OCaml program.

Understand the Configuration File

In the OMake.ini file, each line configures an individual executable. The syntax for each line is as follows:

  • Executable Name: Begins with the name of the executable.
  • Equal Symbol (=): Follows the executable name, acting as a separator.
  • Working Directory and Source Files: On the right-hand side of the equal symbol. The first entry should be the working directory, followed by the source files. These are separated by spaces.

Example format:

[Executable Name] = [Working Directory] [File1] [File2] ...

Example

Suppose you have an executable named hello. You want to compile it using the files hello.ml and world.ml located in the directory src. Your OMake.ini should look like this:

hello = src hello.ml world.ml

Alternatively, if you want OMake to automatically include all .ml files in the src directory, simply write:

hello = src

In this case, OMake will scan the src directory and automatically add all .ml files it finds.

License

Licensed under MIT.