Safe-CMS - Censorship is a thing of the past

Hi @Shane, I’m using Windows 8.1 :slightly_smiling_face:

4 Likes

Perfect, that’s all the testing slots filled up, thanks!

I’ll send out a zip file containing the executable for your platform on Friday 16th, giving you all 8 days to get back to me with any issues and thoughts before the release date. @upstate @srini @AndyAlban @jlpell @JPL

10 Likes

I really like the fact you’re so organised :smiley:

9 Likes

Outside of this place I run a small consultancy, at the moment I’m contracting out 3 1/2 days of my time per week, the other 1 1/2 days of that time is at the moment spent on Safe-CMS and related products, so I’m treating this like a job since working on these products is actively costing me billable hours.

Given the cost of this project is based entirely on how long it takes, it’s important to me that I’m efficient and fast when working on it. :stuck_out_tongue:

21 Likes

Imagine what @Shane could do working five days a week in SAFE Apps. Just saying :wink:

22 Likes

Hi all, been a little while since an actual update of substance, mostly because most of the share-able things are already complete.

Below you can see an (unfinished) screenshot of the template editor, complete with a working (but minimally-featured) development environment for simple HTML, CSS and Javascript (the status indicator at the top right will be changing, so ignore that).

At the moment, this flow works as follows:

  • Select a template (there are 3 default to choose from or you can create your own)
  • Edit the CSS, Javascript and wrapper HTML
  • Save the template
  • Your CSS, JS and HTML is linted, minified then compressed behind the scenes and converted to a single javascript file (template.js).
  • On publish, this template.js file replaces the template.js already uploaded to your website
  • All pages on your blog have a script tag pointing to template.js loaded asynchronously (so you can update every page on your blog by modifying a single mutable data)

It’s that simple. :slight_smile: I will get syntax highlighting working in the next 24 hours.

Timelines

I’m due to deliver the betas to our test group on Friday, this may be delayed to Sunday - this isn’t because of development issues or any challenges encountered, but instead real life commitments, it’s my girlfriend’s birthday this weekend and I’ve promised to go away with her to celebrate it. The “may” is based on how much work I can accomplish in the rest of this week, since I’ve essentially lost an entire day. Either way, we’re still very damn close to our deadline and the product will be released on time.

Edit

I should have said: I’ll also be adding a button in the next day which can be used to preview your template before committing it to the SAFE Network. :slight_smile:

22 Likes

One whole day spent celebrating with your friend will save you 10 whole days hunting bugs :slight_smile:

2 Likes

Hi @Shane, I was just able to catch up with this thread, congratulations for what you’ve built already so fast!
I’m particularly interested in understanding more about the following comments you made

Are you building safe_client_libs and/or packaging the safe_app_nodejs yourself?

Because you shouldn’t need to worry about a C++ compiler or Rust if you are building a NodeJs app. The only thing you should need is to have the safe-node-app npm package as a dependency in your package.json and that also takes care of pulling the safe client libs for your platform. Then as you say, you just need the Authenticator/browser to authorise your app.

1 Like

Hi @bochaco - this is true if you’re only testing your applications against the live environment, but to use mock routing and test locally, you have to build it yourself, no? This requires (on Windows) The Rust Cargo environment, which in turn requires a cpp compiler in your %path%.

In that case it’s also the same, you can just download the SAFE Browser packaged for mock routing (we didn’t release such a version for Peruse yet but we did for Beaker), and when npm installing the safe-node-app package in your app just make sure you set the env. var NODE_ENV=dev, with this set the safe_app lib downloaded will be the one for mock routing as well, so your app can connect to mock.

3 Likes

I would say you’re well a head of schedule… give your self the personal time you need. We’ll still be here ready to test things out when you are. I doubt anyone will cry foul if we have to wait another week, or four, or forty… girlfriends are important.

7 Likes

Hello all, sorry for the delay!

First of all, what you want to know: The beta builds will be delivered in the next 24 hours - I had some illness trouble (of my own fault) after going to a big party and inhaling a bunch of bonfire smoke. Silly me. :slight_smile:

Template editing

Previewed here for you in this video is me editing the default template which comes with the CMS, obviously, the app is much sharper than displayed here as I’m downsizing 1080p video to 720p:

As of right now I have only two minor things left to do:

  • Selecting which template you want to use on a domain (uploading the template.js file)
  • Adding the “hide Built with Safe-CMS” option to the settings page.

In the last week I’ve accomplished the following:

  • Finalised the simple example template
  • Templates now compile down to a single, compressed, distributable file.
  • Templates can now be previewed
  • Support for Javascript in templates has been added
  • Fixed a TON of minor bugs in testing
  • Improved filesystem performance

I’ve been playing a little bit of codegolf to try and get the template size as small as possible, here is some (pre-compression, white-space removal, etc) code as an example if you want a little bit of fun:

codegolf

The way that this has been built means that it only makes modifications / enhancements to the delivered HTML, meaning the pages are crawlable and can be read in the browser (in a basic format) before the template loads.

Again, I can only apologise for the delay in delivering the betas, it’s absolutely my own fault. I don’t foresee this delay effecting the release date, I’m still planning to publish the code and builds this weekend on Github.

Thanks all!

28 Likes

Hi Guys, this is a tiny, tiny update, but I just wanted to show off the first website ever fully made using the Safe-CMS, which can be found here:

safe://blog.safecms/

All I’ve done to create this website is:

  • Create a domain
  • Select the default template, choose the domain I’ve created and click “publish”
  • Write a post on this domain at “hello-world.html” and click publish
  • Write a post on this domain at “index.html” and click publish

It took me around 60 seconds in total. :slight_smile:

The eagle-eyed among you will notice the template.js file here: safe://blog.safecms/template.js, this is the total uploaded size (1.6kb) of the default template, including wrapping HTML, CSS and JS, as well as the bindings to render the scripts and styles to the page.

25 Likes

I’m waiting on an FFI bug with Electron to be fixed before I can deliver the beta packages. :slight_smile:

7 Likes

Brilliant work! This is a great tool and really shows how powerful the SAFENetwork will be.

6 Likes

@Shane inspiration

:stuck_out_tongue:

1 Like

I have it building on MacOS now and did some basic user testing with @AndyAlban in the office:

He’s in the process of building his own custom template now, and I’m sure he’ll share it here once he’s done.

I’m not sure when I’ll get the linux test builds out, it should be fairly soon - I just want to fix the few small issues Andy has raised and stuff I noticed while he was testing.

Either way, this is a really good day for the project:

  • It builds on another operating system
  • It works when you open it
  • All the functionality works as expected

Happy times. :slight_smile: PS: apologies for the terrible mobile phone video.

13 Likes

I’ve added a settings page, containing the option to switch off the “Built with SAFECMS” button in the default template, as discussed here: An open discussion: Should the default Safe-CMS template contain a "Built with" advert?

In addition to this, I’ve also given power users the option to disable the Medium editor used for posts and to instead use the HTML editor provided for creating templates. This allows people with a strong knowledge of HTML to write their posts without the restrictions of a WYSIWYG editor. @happybeing I will be adding Markdown support within the next 2 weeks, for you in particular. :slight_smile:

The settings page can be seen here:

11 Likes

Fantastic :slight_smile:

UPDATE:
@Shane just thought of a new feature (sorry) and probably not too hard…

  • ability to publish to both web and safe (eg via an ftp upload - I have that with my hosting service and I could provide some free accounts if others want them)

I think this would be great, especially with a template that encourages www viewers to learn about SAFEnetwork. Say a footer with… “This blog is also available on the SAFEnetwork (alpha2) - a new secure, autonomous Internet” with a link to a suitable landing page introducing SAFE and with links for different visitors (eg view websites / publish a blog using Safe CMS / develop apps on SAFEnetwork).

I know it doesn’t really fit the SAFE ethos, but as a way to encourage people to blog and publish while introducing the SAFEnetwork to many more readers, bloggers and devs it might be worth it.

I’d certainly be interested in dual publishing a blog about what I’m working on (if I can find the time) and I’m much more likely to bother if it gets visitors who don’t yet have Peruse and alpha2 access.

EDIT: feature request issue 14 raised on github.

12 Likes

Yep, that’s a good idea. I’ll have to look in to it, I know there is already a NodeJS package for FTP client support: GitHub - mscdex/node-ftp: An FTP client module for node.js, but it means a whole bunch of re-tweaking code which has already been tested and I’m remiss to go back and add what is, essentially, a major feature this close to launch.

I’ll be publishing the Github repo within the next 72 hours, so I’ll send it over then and you can raise it as a feature request, I’m definitely interested in getting this in for V2.

It’s worth mentioning, I’ve also bought the domain safecms.org (empty at the moment) so I can redirect people to there with an explanation, a link to the primer, etc - I’ve got a local version of a simple safe-cms website, I just haven’t got round to pushing it live and setting up LetsEncrypt SSL yet.

15 Likes