Page MenuHomeFreeBSD

New Port: textproc/smi
ClosedPublic

Authored by junovitch on Sep 4 2015, 1:13 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Mar 31, 1:38 PM
Unknown Object (File)
Sun, Mar 24, 11:35 PM
Unknown Object (File)
Thu, Mar 21, 11:46 PM
Unknown Object (File)
Mar 9 2024, 2:17 PM
Unknown Object (File)
Mar 2 2024, 9:33 PM
Unknown Object (File)
Mar 2 2024, 9:33 PM
Unknown Object (File)
Dec 24 2023, 3:46 PM
Unknown Object (File)
Dec 24 2023, 3:46 PM
Subscribers
None

Details

Summary
New Port: textproc/smi
Smi is a Simple Markup Interpreter / filter for simplified Markup dialect.
smi can be fed text in Markdown, and return HTML output.  smi can be fed
HTML, and return the markup translated to entities.  I use smi as a filter
for devel/cgit to parse the README.md files, returning HTML output.  I am
also using it to markup wiki pages, for a git backed wiki.  The use cases
are limited only by your imagination.

WWW: http://BSDforge.com/projects/textproc/smi/

PR:		196224
Submitted by:	Chris Hutchinson <portmaster@bsdforge.com>
Approved by:	feld|delphij|pgollucci (mentor)
Test Plan

Poudriere:
https://bugs.FreeBSD.org/bugzilla/show_bug.cgi?id=196224#c5

Portlint:
portlint -AC

looks fine.

Runtime:
The port appears to convert markdown to HTML as intended.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

junovitch retitled this revision from to New Port: textproc/smi.
junovitch updated this object.
junovitch edited the test plan for this revision. (Show Details)
junovitch added reviewers: feld, delphij, pgollucci.
feld requested changes to this revision.Sep 4 2015, 2:38 PM
feld edited edge metadata.
feld added inline comments.
textproc/smi/Makefile
7 ↗(On Diff #8490)

use ${PORTNAME} instead of smi -- less churn if the software is ever renamed

23 ↗(On Diff #8490)

I opened up the config.mk. I personally would prefer to be a bit more specific on this REINPLACE in the event that somehow "cc" ends up elsewhere in the file (unlikely, but I'm paranoid). It also has "g" for global replace, but you really only intend to replace it once... get what I mean?

Also, there's the following in config.mk:

# paths
PREFIX = /usr/local
MANPREFIX = ${PREFIX}/share/man

/usr/local shouldn't be hardcoded and neither should MANPREFIX as these are fully configurable in the ports tree.

I'm curious to know if this thing would be perfectly happy with changing CC = to CC ?=, etc. If so, you could just do something like:

@${REINPLACE_CMD} -e 's|^CC =|CC ?=|' -e 's|^PREFIX =|PREFIX ?=|' -e 's|^MANPREFIX =|MANPREFIX ?=|' ${WRKSRC}/config.mk
This revision now requires changes to proceed.Sep 4 2015, 2:38 PM

Noted. I'll address these and follow up at a later date.

junovitch edited edge metadata.

Address comments

Much of this appeared to be a hold over from the original textproc/smu port (https://github.com/Gottox/smu) that this is based on. If this is approved, I'll push the suggestions over to the textproc/smu maintainer as they are valid there.

The upstream went to Github just before the PR was submitted in December 2014. Keeping all the legacy probably made sense then Chris said he has been working new features he intended to get in after this port was added. If that is the case, he can address them in the smi port code rather than needing to address this in ports.

textproc/smi/Makefile
24 ↗(On Diff #8621)

The ?= is a shell parse error on the port but I've addressed the intent of this. I've tested with PREFIX=/opt and CC=gcc48 in my make.conf and validated that this does the right thing.

pgollucci edited edge metadata.
This revision was automatically updated to reflect the committed changes.