![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
= Radius -- Powerful Tag-Based Templates
{rdoc-image:https://github.com/jlong/radius/workflows/CI/badge.svg}[https://github.com/jlong/radius/actions] {rdoc-image:https://codeclimate.com/github/jlong/radius.png}[https://codeclimate.com/github/jlong/radius] {rdoc-image:https://coveralls.io/repos/jlong/radius/badge.png}[https://coveralls.io/r/jlong/radius]
Radius is a powerful tag-based template language for Ruby inspired by the template languages used in MovableType[http://www.movabletype.org] and TextPattern[http://www.textpattern.com]. It uses tags similar to XML, but can be used to generate any form of plain text (HTML, e-mail, etc...).
== Usage
With Radius, it is extremely easy to create custom tags and parse them. Here's a small example:
require 'radius'
context = Radius::Context.new do |c| c.define_tag 'hello' do 'Hello world' end c.define_tag 'repeat' do |tag| number = (tag.attr['times'] || '1').to_i result = '' number.times { result << tag.expand } result end end
parser = Radius::Parser.new(context, :tag_prefix => 'r')
puts parser.parse(%{A small example:\n<r:repeat times="3">* <r:hello />!\n</r:repeat>})
Output:
A small example:
== Quick Start
Read the QUICKSTART file to get up and running with Radius.
== Requirements
Radius does not have any external requirements for using the library in your own programs.
Ragel is required to create the ruby parser from the Ragel specification, and both Ragel and Graphviz are required to draw the state graph for the parser.
== Installation
It is recommended that you install Radius using the RubyGems packaging system:
% gem install --remote radius
== License
Radius is released under the MIT license and is copyright (c) 2006-2025 John W. Long. A copy of the MIT license can be found in the LICENSE file.
== Roadmap
This is a prioritized roadmap for future releases:
Clean up the current code base. [Done]
Add support for multi-level contexts: tags should be able to be defined to only be valid within other sets of tags. [Done]
Create a simple DSL for defining contexts. [Done]
Optimize for speed, modify scan.rl to emit C.
== Development
The latest version of Radius can be found on RubyForge:
http://github.com/jlong/radius
If you are interested in helping with the development of Radius, feel free to fork the project on GitHub and send me a pull request.
John Long :: http://wiseheartdesign.com
FAQs
Unknown package
We found that radius demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.