processing / processing/processing-website

Generate `.pdez` files for each code example

Open
#445 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Examples Help Wanted
Dominant language
MDX
Stars
90
Forks
122
Avg merge
1h 43m
Merged PRs (30d)
3

Description

Context

As part of the effort to improve the Processing website and editor, a new feature has been introduced to allow users to open sketches and libraries directly in the Processing editor by clicking on a link. This will allow us to add a link to each example, opening the corresponding sketch directly in the Processing editor.

Problem statement

When browsing the examples page we want users to be able to run the examples in the Processing Development Environment (PDE). Currently, it can be time-consuming and confusing for users to manually copy and paste each tab of an example into the PDE and ensure that all required assets (e.g., images, fonts) are present.

The planned "Open in Processing Editor" feature aims to address this issue. However, it requires that each example have a .pdez file, which is not currently generated when running the script that copies examples over from the processing-examples repository.

Proposed solution

To address this issue, we can modify the existing updateExamples script that copies Processing code for each example from the processing-examples repository to the Processing website. Specifically, we can update the script to automatically generate .pdez files for each example and add them to the corresponding example folder in addition to the existing .pde files and any other files that are already being copied over.

Benefits

This change would greatly benefit users who want to quickly run examples from the website without having to manually copy and paste each tab into the PDE. By automating the process of generating .pdez files for each example, we can improve the user experience and make it easier for people to get started with Processing.

References

The process of updating examples on the website is described in details here:
https://github.com/processing/processing-website/blob/main/docs/examples.md

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with scripts/updateExamples.js and read docs/examples.md for how the example-copying process works. Trace how example folders and existing files are handled, then verify that each copied example receives a .pdez file alongside its .pde files and other assets. Confirm the generated files support the planned “Open in Processing Editor” links.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.