WallOli is a cross-platform tool designed to display a grid of videos across one or multiple screens. Leveraging VLC for video playback, this application ensures smooth and synchronized video presentations.
Projects
-
Ranger
Ranger is a formatter for date and time ranges, based (somewhat loosely) on Adam Shaw’s
formatRangealgorithm in fullCalendar.Some Examples
<?php use OpenPsaRangerRanger;$ranger = new Ranger(‘en’); echo $ranger->format(‘2013-10-05’, ‘2013-10-20’); // Oct 5–20, 2013 echo $ranger->format(‘2013-10-05’, ‘2013-11-20’); // Oct 5 – Nov 20, 2013
$ranger = new Ranger(‘en_GB’); echo $ranger->format(‘2013-10-05’, ‘2013-10-20’); // 5–20 Oct 2013 echo $ranger->format(‘2013-10-05’, ‘2013-11-20’); // 5 Oct – 20 Nov 2013
$ranger = new Ranger(‘de’); echo $ranger->format(‘2013-10-05’, ‘2013-10-20’); // 05.–20.10.2013 echo $ranger->format(‘2013-10-05’, ‘2013-11-20’); // 05.10.–20.11.2013
Usage
To use Ranger in any other locale than
"en", you will need to have thephp-intlextension installed.Instantiate ranger with the name of your locale as the parameter. You can also pass
nullto use theini.default_localesetting. Afterwards, you can callformat()with two date parameters. Accepted types areDateTimeobjects- strings (any format that
DateTimecan read) - Unix timestamps
null(which means current date).
- strings (any format that
Output Customization
<?php use OpenPsaRangerRanger; use IntlDateFormatter;$ranger = new Ranger(‘en’); $ranger ->setRangeSeparator(‘ and ‘) ->setDateTimeSeparator(‘, between ‘) ->setDateType(IntlDateFormatter::LONG) ->setTimeType(IntlDateFormatter::SHORT);
echo $ranger->format(‘2013-10-05 10:00:01’, ‘2013-10-05 13:30:00’); // October 5, 2013, between 10:00 AM and 1:30 PM
-
Project Donations for WooCommerce
Collect donations for different projects with a WooCommerce product.
If you are like me, you work on several projects and would like to simply collect donations for them, without bothering creating and configuring a product for each project.
This plugin is mostly intended to be easy to set up. It is mostly usefull if you want to get donations and need or already use WooCommerce platform.
-
PHP Library for Project Version Management
This library provides tasks for automating versioning of your PHP projects.
It allows you to increment the version based on different levels (major, minor, patch, dev, beta, rc), and update version references in various files such as PHP files, README.md, package.json, and readme.txt.
Installation
Run the following command in your project directory:
composer require --dev magicoli/php-bump-libraryAnd add the following script to your
composer.jsonfile:"scripts": { "bump-version": "robo --load-from=vendor/magicoli/php-bump-library/RoboFile.php bump:version" }Usage
composer bump-version [level]Replace
[level]with the desired level of version increment, such asmajor,minor,patch,rc,beta, ordev. If you ommit it, the default level ispatch.Alternatively, you can run the script directly with the following command:
robo bump:version # or robo --load-from=path/to/RoboFile.php bump:versionMake sure to adjust RoboFile.php to the actual path of the file in your project.
About Versioning
Semantic Versioning follows a specific order of version increments:
Development stages (M.m.p-stage):
- Dev: development versions that are not yet stable or released.
- Beta: pre-release versions that are closer to the stable release but may still have minor issues.
- RC: release candidates, which are close to the final release but may require additional testing.
Releases (M.m.p):
- Patch: backward-compatible bug fixes.
- Minor: added functionality, still backward-compatible manner.
- Major: big bada boom.
Note that
dev,beta, andrcversions are considered inferior to the normal versions and are typically used in pre-release stages or development cycles:1.0-dev<1.0-beta<1.0-rc<1.0.For example, if your version is
1.0.0and you bump it on thedevlevel, new version will be1.0.1-dev(note the pach increment). If you bump thedevtobeta, it will keep its main version and become1.0.1-beta. And if you bump1.0.1-betawithout arguments, the new version will be1.0.1.License
This library is licensed under the AGPL-v3 License.
-
Lodgify Link for WooCommerce
Currently, the plugin simply provides booking id and user-defined amount fields to WooCommerce products, to allow keeping track of payments related to externally managed bookings.
The final goal will be to use this booking id to fetch booking data from Lodgify and display a comprehensive detail of the reservation in WooCommerce order (accommodation, name of guest, booking dates, deposit and total amount…)
-
Documents from Git – Oli’s version
This WordPress Plugin lets you easily publish, collaborate on and version control your [Markdown, Jupyter notebook] documents directly from your favorite remote Git platform, even if it’s self-hosted.
The advantages are:
- Write documents in your favorite editor and just push to your remote repository to update your blog instantly
- Use the power of version control: publish different versions of the document in different posts, i.e. from another branch or commit than latest
master - Easy to update by your readers via pull requests, minimizing the chance of stale tutorials
The following document types are currently supported:
- Markdown
- Jupyter notebooks (only for public repositories)
The following platforms are currently supported:
- Github
- Bitbucket
- Gitlab
Usage
Note, this plugin uses Github’s wonderful
/markdownAPI to render to HTML. This comes with 2 caveats:- Unless authenticated, the rate limit is set at 60 requests per minute. Since v1.1.0 the plugin is capable of statically caching content. In case that’s not dynamic enough for you, your only option currently is to not use any cache in which case every document will be pulled from your provider every time someone opens it on your site. Then it’s strongly recommended to create a Github access token and register it with the plugin. Then the rate limit will be set to 5000 requests per hour. See Global attributes section for details on how to do that.
- The Markdown content cannot exceed 400 KB, so roughly 400 000 characters incl whitespace. If not a monographic dissertation, this should not be an applicable limit though.
Configuration
In the main menu Settings > Documents from Git you can set all important global settings.
Note: previous
config.jsonis deprecated now due to security concerns.Shortcodes
The features of the plugin are provided through shortcodes. You can use them in your posts, pages or custom post types.
Publish documents
[git-<platform>-<action>]The document-specific shortcode<platform>can be one ofgithub: if you use Github as your VCS platformbitbucket: if you use Bitbucket as your VCS platformgitlab: if you use Gitlab as your VCS platform
<action>can be one ofmarkdown: Render your Markdown files hosted on your VCS platform in Github’s rendering stylejupyter: Render your Jupyter notebook hosted on your VCS platform (only for public repositories)checkout: Renders a small badge-like box with a link to the document and the date of the last commithistory: Renders a<h2>section with the last commit dates, messages and authors
Manipulate rendering style
[git-add-css]adds a<div id="git-add-css" class="<classes_attribute>"to wrap content. That way you can manipulate the style freely with additional CSS classes. Follow these steps:- Add a CSS file to your theme’s root folder, which contains some classes, e.g.
class1,class2,class3 - Enqueue the CSS file by adding
wp_enqueue_style('my-style', get_template_directory_uri().'/my-style.css');to the theme’sfunctions.php - Add the enclosing
git-add-cssshortcode to your post with the custom CSS classes in theclassesattribute, e.g.:
[git-add-css classes="class1 class2 class3"] [git-gitlab-checkout url=...] [git-gitlab-markdown url=...] [git-gitlab-history url=...] [/git-add-css]Attributes
Each shortcode takes a few attributes, indicating if it’s required for public or private repositories:
url: The URL of the document in the repository- Type: string
- Action: all except
git-add-css - Public repo: :ballot_box_with_check:
- Private repo: :ballot_box_with_check:
user: The user name (not email) of an authorized user- Type: string
- Action: all except
git-add-css - Public repo: :negative_squared_cross_mark:
- Private repo: :ballot_box_with_check:
token: The access token/app password for the authorized user- Type: string
- Action: all except
git-add-css - Public repo: :negative_squared_cross_mark:
- Private repo: :ballot_box_with_check:
cache_ttl: The time in seconds that the plugin will cache, only forcache_strategy=static.- Type: integer
- Action: all except
git-add-css - Public repo: :negative_squared_cross_mark:
- Private repo: :negative_squared_cross_mark:
cache_strategy: Onlystaticcaching is implemented so far.dynamiccaching is on the way!- Type: integer
- Action: all except
git-add-css - Public repo: :negative_squared_cross_mark:
- Private repo: :negative_squared_cross_mark:
limit: Limits the history of commits to this number. Default 5.- Type: integer
- Action:
history - Public repo: :negative_squared_cross_mark:
- Private repo: :negative_squared_cross_mark:
classes: The additional CSS classes to render the content with- Type: string
- Action:
git-add-css - Public repo: :ballot_box_with_check:
- Private repo: :ballot_box_with_check:
Caching
Often we need to prioritize speed when loading content and, in addition, it is very costly to fetch, load and format the content every time we need to read the content of the post.
This plugin soon offers 2 methods for caching,
staticanddynamicwhich can be set via thecache_strategyproperty.- Static caching (
cache_strategy=static)
This is the default strategy, as it doesn’t require any user action.
The property
cache_ttlsets how many seconds the content cache will keep alive.Currently there’s no way to flush the cache manually. However, changing
cache_ttlor the historylimitwill create a new cache.- Dynamic caching (
cache_strategy=dynamic)
This is not implemented yet. See #20 for details.
TokenauthorizationYou need to authorize via
userandtokenif you intend to publish from a private repository. You don’t need to authorize if the repository is open.However, keep in mind that some platforms have stricter API limits for anonymous requests which are greatly extended if you provide your credentials. So even for public repos it could make sense. And unless you use this plugin’s caching capabilities, it’s strongly recommended to register a Github access token regardless of the VCS hosting platform, see the beginning of the chapter.
How to generate the
tokendepends on your platform:- Github: Generate a Personal Access Token following these instructions
- Bitbucket: Generate a App Password following these instructions
- Gitlab: Generate a Personal Access Token following these instructions
This plugin needs only Read access to your repositories. Keep that in mind when creating an access token.
Examples
We publish our own tutorials with this plugin: https://gis-ops.com/tutorials/.
- Publish Markdown from Github
[git-github-markdown url="https://github.com/gis-ops/tutorials/blob/master/qgis/QGIS_SimplePlugin.md"]- Publish Markdown from Github with 1 hour cache
[git-github-markdown url="https://github.com/gis-ops/tutorials/blob/master/qgis/QGIS_SimplePlugin.md" cache_ttl="3600" cache_strategy="static"]- Publish Jupyter notebook from Github
[git-github-jupyter url="https://github.com/GIScience/openrouteservice-examples/blob/master/python/ortools_pubcrawl.ipynb"]- Publish from a private repository
[git-bitbucket-jupyter user=nilsnolde token=3292_2p3a_84-2af url="https://bitbucket.org/nilsnolde/test-wp-plugin/src/master/README.md"]- Display last commit and document URL from Bitbucket
[git-bitbucket-checkout url="https://bitbucket.org/nilsnolde/test-wp-plugin/src/master/README.md"]- Display commit history from Gitlab
git-gitlab-history limit=5 url="https://gitlab.com/nilsnolde/esy-osm-pbf/-/blob/master/README.md"]- Use additional CSS classes to style
The following example will put a dashed box around the whole post:
[git-add-css classes="md-dashedbox"] [git-github-checkout url="https://github.com/gis-ops/tutorials/blob/master/qgis/QGIS_SimplePlugin.md"] [git-github-markdown url="https://github.com/gis-ops/tutorials/blob/master/qgis/QGIS_SimplePlugin.md"] [git-github-history url="https://github.com/gis-ops/tutorials/blob/master/qgis/QGIS_SimplePlugin.md"] [/git-add-css]With the following CSS file contents enqueued to your theme:
div.md_dashedbox { position: relative; font-size: 0.75em; border: 3px dashed; padding: 10px; margin-bottom:15px }div.md_dashedbox div.markdown-github { color:white; line-height: 20px; padding: 0px 5px; position: absolute; background-color: #345; top: -3px; left: -3px; text-transform:none; font-size:1em; font-family: "Helvetica Neue",Helvetica,Arial,sans-serif; }
Installation
WordPress.org
The latest version is on Oli’s GitHub repository
https://github.com/magicoli/documents-from-git
There is no automatic update process from GitHub. You need to download the latest release and upload it to your WordPress installation, or, for advanced users, clone the repository into your
wp-content/pluginsfolder and use git features.Note: The release from the original author on WordPress plugin store is deprecated and does not receive updates Documents from Git.
Troubleshooting
For troubleshooting and frequently asked questions, please refer to the FAQ page.
Acknowledgements
Contributions from other projects
- Nils Nolde, former maintainer of the plugin.
The file structure has been reorganised from the original version to make it more maintainable and to follow WordPress best practices, mainly bringing the wordpress file structure to the root folder, so applying this repo modifications to an original clone might need some extra preparation, but is not impossible.
github-markdown-css: CSS project for the Github flavored Markdown style, License MIT- This plugin maintains a copy of the CSS file
nbconvert: WordPress plugin to convert Jupyter notebooks into blog posts, License MIT- The idea for this plugin was mainly inspired by
nbconvertand borrows some of the HTML and the CSS for Jupyter notebooks
- The idea for this plugin was mainly inspired by
- Jason Long: Git logos under Creative Commons Attribution 3.0 Unported License
