Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Collaboration on parts of the code? #1

Closed
voxpelli opened this issue Feb 22, 2019 · 5 comments
Closed

Collaboration on parts of the code? #1

voxpelli opened this issue Feb 22, 2019 · 5 comments

Comments

@voxpelli
Copy link

Neat with another node.js project doing these kinds of things!

I've opted for a very modular approach in my endpoint to enable others who want to build similar approaches to not have to reinvent every approach and thus that we can collaborate and improve some shared parts while at the same time innovate and experiment with the ones that sets us apart or that we feel takes the wrong approach.

Here's the list of modules I've splited form my main project: https://github.com/voxpelli/webpage-micropub-to-github#modules-used

My main project is basically just a glue between those three modules.

Maybe we could collaborate on the micropub-express and github-publish? Or is there something that you are doing that is pushing in another direction than I am with those modules? If so, I would be interested in hearing your thoughts and ideas on that!

@paulrobertlloyd
Copy link
Collaborator

paulrobertlloyd commented Feb 22, 2019

👋🏻 Hello again @voxpelli! Your endpoint was the first of many I tried, hacked away at and played with, all of which informed and inspired the design of this app. So thank-you for writing it.

In general, I’ve tried to use existing packages. For example, to parse Microformats I’ve used Glenn Jones’ microformat-node. To discover post types, I’ve used Prateek Saxena’s post-type-discovery (although as it was returning errors I copied the code for the sake of expediency. I really need to file issues or submit fixes so I can include it as a dependency).

As to your modules:

  • I looked at using node-micropub-express, but wrote my own code for a few reasons. Firstly, I felt I needed to understand how this stuff all works, which was only possible by writing it from scratch. Secondly, the module doesn’t provide Media Endpoint support… although, come to think of it, I can deal with that separately as it uses a different route. Which is to say, perhaps I should take another look at your module to see if I can incorporate it!

  • I hadn’t noticed node-github-publish, and it looks like a good candidate for providing my needs… although it currently lacks support for deleting files, and that’s one of the few things my app does do at the moment! 😂

  • With regards to node-format-microformat, while there is definitely some cross over (and some things I can take from its design), I suspect this is where I’d need to diverge, as I want to allow users to be able to use their own templates (note that Hugo supports YAML, JSON and TOML syntaxes for frontmatter data). If your module were to support different frontmatter types, that might help, but what if a user wanted to use another CMS? Kirby has its own way of formatting its content files, for example.

Anyway… that’s an overly long explanation, but the short answer is: YES, I’d love to collaborate on some of these shared pieces! My long term goal for IndieKit is to support multiple publishing destinations (GitHub, GitLab, Bitbucket… maybe even good ’ol SFTP!) and other IndieWeb standards like Webmention; having shared components would make my life much easier!

In terms of collaboration, I think adding delete functionality to github-publish might be a good place to start. It’s a scoped piece of work, with little variance of the different options it would need to provide to consuming applications. I’ll see if I can make a PR to add that in.

Personally, I’m very new to all this — I’m surprised I’ve managed to build this much to be honest. Building a Micropub server has been a really useful means of better understanding how Node and JavaScript works, but I still have so much more to learn. Collaborating with you @vipickering would only help accelerate this process, I feel. 🤗

@voxpelli
Copy link
Author

Thanks for the excellent explanation of your thinking, makes a lot of sense to me!

Agree that it sounds like the adding of deletion to github-publish would be a very good first candidate for closer collaboration between us! Would love to have that as well – deletion is really a feature I should integrate with. Is that module in general and that feature in particular something you would find useful as well @vipickering?

I agree with most of your goals, I'm aiming for similar things but from different angles and at a different pace 😊

My highest priority for my micropub endpoint is the Media Endpoint, would certainly be interesting to collaborate on as a second step 👍

@vipickering
Copy link

vipickering commented Feb 24, 2019

I've had a look at github-publish and it seems like it wouldn't be too much effort to swap out my Github code for it.

Now I've cobbled together all the basic functionality (on my own server), the next step was to modularise it. So it makes sense to start collaborating and understand other peoples needs as well as my own.

From speaking to others I've found people can have differing specific needs, even on a static site, so the idea of drop in modules appeals to me.

Currently I don't support updates or deletes, I couldn't come up with a good user need for myself, that wasn't simpler than opening the markdown file and deleting/updating the file manually, but I'm happy to pitch in where I can to help you do it.

@paulrobertlloyd on your point with node-format-microformat, that was also a pain point for me when looking at other peoples implementations and a key reason why I rolled my own solution. My approach has a formatter for each post type, swapping for another is as easy as pointing at a new file and rolling some specific code. For example I don't have a formatter in here for longform articles as I prefer to hand crank those, but others might want to use Quill etc and could drop in their own. Side note, I recently deleted my ownyourswarm formatter as I left Instagram, but I would be happy to dig it out of the github history and refine it should you want it.
This could do with a friendly more modular code approach, but the notion of allowing anyone to write their own post formatter seems like a sound approach to take, given quite how varied peoples CMS choice or frontmatter options may be.

Time-wise my availability to help will be spotty over the next few months, I'm emmigrating next month and starting a new job, but I'll help where I can :-)

@grantcodes
Copy link

Hey I opened a new repo to track ideas for collaborating on a new micropub endpoint middleware at https://github.com/grantcodes/future-micropub-endpoint

Would love to get your input and/or help as indiekit looks really well made!

@paulrobertlloyd
Copy link
Collaborator

paulrobertlloyd commented Jul 26, 2019

Closing this issue to ensure all discussion is centralised at the repo @grantcodes created.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants