C::Blocks Advent Day 8

This is the C::Blocks Advent Calendar, in which I release a new treat each day about the C::Blocks library. Yesterday I showed one way to build a (mildly) complex data structure, including handling pointers and managing memory. Today I will explain how to tightly control access to pointers using classes and C::Blocks::Object::Magic.

Dist::Zilla Takes it in the Name

Another Pod post here in the Dist-pen.

In my last post one saw how you can change the order of the 'sections' of your POD by simply not using the '@Default' template and using you own custom template. You also saw haw you can use other peoples templates by simply installing them and the swapping them out for the [@Default] template.

Today I am going to have a closer look at the [Name] section.

This is one of the more simplistic section templates, it only produces the following;

=head1 NAME

Database::Accessor::Manual - What is Database::Accessor, and how do I use it?
It will look in your POD fro the following comments
  • # ABSTRACT:
  • # PODNAME:
So to produce the above my original Pod is;

Rakudo.js update

I have added support for uncached methods (ones that are looked up dynamically by find_method on the metaclass instance rather then set by nqp::setmethcache) by putting an ES6 Proxy inside of our prototype chain.

It's the first use of ES6 that isn't merely a convenience as I don't know of a way to do it without that without introducing a serious performance penalty.
Nqp-js has been refactored to use instances of a class with a VMArray repr instead of a custom JS class wrapping array.
After figuring out I need to pass the --max-old-space-size option to node (which stops node.js from aborting rakudo.js if it does a gc run and judges that we use more memory then we deserve even if we have free RAM around), rakudo.js finally compiled the full setting.

Perl 5 Porters Mailing List Summary: December 1st-7th

Hey everyone,

Following is the p5p (Perl 5 Porters) mailing list summary for the past week.

Enjoy!

C::Blocks Advent Day 7

This is the C::Blocks Advent Calendar, in which I release a new treat each day about the C::Blocks library. Yesterday I illustrated the many ways you generate or modify C source code. Today I discuss basic facilities for handling pointers and building C data structures.

Dist::Zilla On Style

Even more POD here on the Dist-Pen today.

I my last post I finally figured out how Pod::Weaver works, a template, weaver.ini file, that has 'Sections', [Name], [Author] etc, that you can change to create your POD document.

I wanted to test just how Pod::Weaver works so I replace '@default' in my 'weaver.ini' whith what the source code of Pod::Weaver::PluginBundle::Default said it was supplying;

My first ever talk at London Perl Workshop 2016

On the day of the event, I reached the center at about 8:45 am with plenty of time to go through the registration procedure. I have been attending the London Perl Workshop for the last 4 years. But this year was little special as I was giving a talk, thanks to Neil Bowers. In fact he helped me prepare the notes and sharing his own experiences.

I was assigned "Room 2" for my talk. When I got there I realised that I didn't have the right connector to connect my laptop with the big screen. Dave Cross was also giving a talk in the same room and he suggested I talk to Mark Keating. Luckily, Mark had spare connector for me. I was sorted and ready to go. I still had 3 hours before my talk, so I attended the talk by Dave Cross about what new features added to perl.

GitPrep v2.5 released today. Theme color become dark blue.

GitPrep v2.5 released today. Theme color become dark blue.

Let's try GitPrep example.

I'm going to implement "wiki" in next release!

Introducing JIRA::REST::Class

Over the past couple months, I've had to take over project management for my DarkPAN project at $EMPLOYER, and the software they're enamored of for that purpose is JIRA.

Unfortunately, JIRA can be a pain in the ass sometimes, and since we're not the only group at $EMPLOYER that uses JIRA, getting things set up the way we need them is not always possible. However, it was possible to manually go through and fix up issues to our standards...

Well, whenever something is manually possible, I look for a way to automate it. I quickly discovered that JIRA has a REST API, so I went looking for a tool to help me use it in Perl.

I found JIRA::REST.

Dist::Zilla Tempate

It is still POD day here at the Dist-Pen

I spent the day trying to get a little deeper into POD::Weaver to understand how it works rather than just aping the three lines I have seen in the odd tutorial or should I say tuturial-ette;

[@Default]

[-Transformer / List]
transformer = List
The fist thing to know about POD::Weaver is if you want to use it any deeper than the above then don't bother going to its home-page on CPAN there is not much there to get started on.

Not faulting the documentation at all it is quite comprehensive and perfect if you are going to create a project like podweaver.

C::Blocks Advent Day 4

This is the C::Blocks Advent Calendar, in which I release a new treat each day about the C::Blocks library. Yesterday I showed how to get information across the boundary between Perl and C with minimal boiler plate. Today I explain how to declare and use C functions. I also explain the killer feature of C::Blocks: declaring C functions and other things within a module that can be used throughout your code.

Saving Breakpoints in the Perl Debugger

I'll state right off the bat that I have re-invented the wheel here. However, I did not know that until I asked on Perlmonks and was pointed to the resources that I couldn't find on Google. It was suggested on Perlmonks that a blog post, even for a re-invented wheel might be good, just for the purpose of getting the information out there. So, here it goes.

If you use the Devel::ptkdb debugger, then you know that one of its features is the ability to save breakpoints (and other info) in a *.ptkdb file that is reloaded the next time you run that debugger.

It's a feature I missed on those occasions where I needed to use the default debugger, not Devel::ptkdb. However, after scrounging around what docs there are on the default debugger, I was able to cobble together the following process:

1 - Create a file .perldb in your home directory and add this code to it.

meta::hack 2016

MetaCPAN is the community developed and maintained website and api for finding and learning about Perl modules. This year, we dedicated a long weekend to improving it and oh what a weekend it was!

Dist::Zilla and Weaver. Play Nice!

Small problem solving day here in the Dist-Pen.

Just a quick post-ette today to resolve the problem I was having in my last post, where I was trying to get [PodWeaver] to work with 'Pod::Elemental::Transformer'.

I was trying to get this;

=head1 Table Of Contents
=for :list
* Database::Accessor::Tutorial::GettingStarted
* Database::Accessor::Tutorial::Basics
=cut 
to work for my POD but it just did not want to play ball with me. I know this should work as I have seen it used in all sorts of other places and in the two tutorials I ran across.

C::Blocks Advent Day 3

This is the C::Blocks Advent Calendar, in which I release a new treat each day about the C::Blocks library. Yesterday I showed how to get information across the boundary between Perl and C. Today I show how to do that for a number of types, including packed arrays, with minimal boiler-plate.

You can import your Metacpan favorites into perlmodules.net!

PerlModules.net is a website that notifies you when your favorite modules get updated, via e-mail or RSS.

As of today, you can now import your favorites from metacpan.org into perlmodules.net.

And if your metacpan favorites list changes in the future, no worries: the corresponding feed in your perlmodules.net account will adapt accordingly.

Static code analysis with Perl and SonarQube

When managing code quality for bigger projects, SonarQube is the de-facto standard for many programming languages. Not for perl, as there has not been any perl integration into SonarQube yet.

We have Perl::Critic, a fantastic linting tool, but what if we could track our Perl::Critic issues in our projects over time? What if we had a webinterface where we could extract statistics about certain issue types? What if we could combine this with code coverage information? All this is about to come...

Come join me on my new open source project "sonar-perl": https://github.com/otrosien/sonar-perl -- I'm looking forward to it!

He's Back!!!

Just when you think the Dist::Zilla is gone, I am going to go back to the Dist-Pen for the next few posts.

I could just spend the next thirty posts or so writing up a new POD each day and posting the results here. I wouldn't learn anything though, I alreay know how to write POD, and I am sure I would loose any readers I might of gained over the last few weeks. So I think I will spare us that and instead re-visit Dist-Zilla today.

I am going to re-vist how I am using [PodWeaver] plugin, as I am facing some thirty POD files that will have a good deal of boiler plate in them and I would like to have some things just done for me.

To investigate how Pod::Weaver works I created only a single POD today 'Manual.pod' with just this in it

C::Blocks Advent Day 6

This is the C::Blocks Advent Calendar, in which I release a new treat each day about the C::Blocks library. Over the last few days I have illustrated how to use C::Blocks to write procedural code, how to get data across the Perl/C divide, including using types to do that concisely, and how to write code that is shared across modules and scripts. Yesterday I provided some benchmarks that I hope give a sense for the performance of C::Blocks, and start to indicate the circumstances when it might be useful. Today I am going to illustrate the many ways you can generate and/or modify your C code using C::Blocks including source filters, interpolation blocks, and the good old string eval.

Perl 5 Porters Mailing List Summary: November 21st-30th

Hey everyone,

Following is the p5p (Perl 5 Porters) mailing list summary for the past week and a half.

Enjoy!

About blogs.perl.org

blogs.perl.org is a common blogging platform for the Perl community. Written in Perl with a graphic design donated by Six Apart, Ltd.