Skip to content

Commit

Permalink
Merge pull request #5 from adhocore/develop
Browse files Browse the repository at this point in the history
Big Refactor
  • Loading branch information
adhocore committed Oct 25, 2017
2 parents 3fea26c + f6737bb commit b1717e7
Show file tree
Hide file tree
Showing 6 changed files with 462 additions and 288 deletions.
18 changes: 16 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,21 @@
sudo: required

git:
depth: 1

language: php
php:
- 5.4
- 5.5
- 5.6
- hhvm
- nightly
- 7.0
- 7.1

install:
- composer install --prefer-dist

script:
- vendor/bin/phpunit --coverage-text --coverage-clover=coverage.xml

after_success:
- bash <(curl -s https://codecov.io/bash)
14 changes: 7 additions & 7 deletions examples/example.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@

use Ahc\HtmlUp;

require dirname(__DIR__).'/vendor/autoload.php';
require dirname(__DIR__) . '/vendor/autoload.php';

$markdown = file_get_contents(dirname(__DIR__).'/readme.md');
$markdown = file_get_contents(dirname(__DIR__) . '/readme.md');

/* You can use any of the three usage methods below */

# usage 1
// usage 1
// $h = new HtmlUp($markdown);
// echo $h->parse();
// echo $h->parse();

# usage 2
// usage 2
// $h = new HtmlUp($markdown);
// echo $h;
// echo $h;

# usage 3
// usage 3
echo new HtmlUp($markdown);
2 changes: 1 addition & 1 deletion readme.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# htmlup [![build status](https://travis-ci.org/adhocore/htmlup.svg?branch=master)](https://travis-ci.org/adhocore/htmlup)

`htmlup` is ultra lightweight (packed in just _250 ncloc_) and uber speedy markdown to html parser written in PHP.
`htmlup` is ultra lightweight and uber speedy markdown to html parser written in PHP.
**Concept** - it splits the markdown into lines and parses to markup one by one, finally applies markdown syntaxes on the markup.
It supports most of the markdown as in [specs](https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet "cheatsheet").

Expand Down
Loading

0 comments on commit b1717e7

Please sign in to comment.