Hi, I guess a Snippet to one programmer, is a piece of Code to another. I have been posting, what I consider to be just little fully functional bare bones code examples, to the Snippets section. I am getting complaints from jdporter that these are not Snippets but are Code. To me they are Snippets..... although fully functional, they lack much error checking, and are solely "proof-of-concept" code, to illustrate how to incorporate the concept into your own larger programs.

But as I read the Snippets page, and it's description, I guess he is right, and I am wrong.

Is there a way for me to go thru the Snippets I posted, and move them to the Code catagory?


I'm not really a human, but I play one on earth. Cogito ergo sum a bum

Replies are listed 'Best First'.
Re: moving nodes from Snippets to Code (why?)
by tye (Sage) on Feb 27, 2008 at 19:35 UTC

    Oh, who cares? No, that was rhetorical. They sound rather snippetish to me and the few I looked at don't look utterly unsnippetish. Yes, it'd be better to get rid of the distinction between "code" and "snippets". Creating sections that were too specialized was a mistake. We should have only one "here's code" section (and Cool Uses For Perl is probably the best format as the categorization features never worked well -- one day somebody may get some kind of tagging system working which makes more sense than trying to create categories). We should also merge poems and obfu into a single "fun" section. No, I wouldn't suggest holding your breath. :)

    - tye        

      Why not just prevent new posts to the other code sections and then suggest all code gets posted to Cool uses for Perl (or just pick one of the code sections)?
      Regarding poetry, I have to respectfully disagree. What other programming language has any significant claim to having cultural value to it? I think that's one of the unique aspects to the Perl community that makes the community and the language so great and I would hate to ever see that marginalized.
Re: moving nodes from Snippets to Code
by jdporter (Paladin) on Feb 27, 2008 at 20:30 UTC

    Unfortunately, it is not possible to move posts to/from the Snippets Section. And that kind of goes to the heart of why I like to discourage people from posting to that section unnecessarily: the snippet nodetype is an ugly stepchild, in several ways. For another example, it has no good categorization or indexing system. (That's why I created the New Snippets Index. But being off-site, it is perpetually at risk of de-resolution, just like its predecessor.) The bottom line is that unless you want to depend on unofficial hacks like New Snippets Index, posting to the Snippets Section is almost like dropping your post in a black hole. Snippets also lack certain other niceties we've come to expect in the other sections. For example, as you discovered, a snippet body can contain only a single <code> block. Note that Code Catacombs has similar (but different) oddities which make it somewhat incompatible with the other sections. So, as tye said, for posting a "normal" post for code, CUFP is probably the best choice, except when it's a "fun" post (obfu or poem).

    Note - In the interest of full disclosure, you should know that I am largely responsible for the prefatory text of Snippets Section, and although I wrote it in good faith, I can't guarantee that it accurately embodies the opinions of those who set site policy.

    A word spoken in Mind will reach its own level, in the objective world, by its own weight

        Oh, interesting. I only looked that the mover available in the Moderation Nodelet.

        Actually... Are you sure that the Snippet Mover isn't gods-only? I get a "permission denied", even on the code view.

        Yeah, that is what I was kind of thinking. I'm not sure how perlmonk's database is set up, but I was assuming that you could do something like "select * from Snippets, where author eq zentara, then for each node found, change Category from Snippets to Code, Gui Programming. So if any janitor wants to do it, they have my consent(if needed).

        But like Tye said, I won't worry about it, but will be more careful where I post in the future.


        I'm not really a human, but I play one on earth. Cogito ergo sum a bum
A reply falls below the community's threshold of quality. You may see it by logging in.