Zeronet: -noclone prefix for files that will not be clonned

Created on 23 Aug 2018  路  7Comments  路  Source: HelloZeroNet/ZeroNet

All 7 comments

@HelloZeroNet @shortcutme

What would be you usecase? You can add directories/files with -default prefix that will be renamed on clone. You can check it on ZeroBlog.

@HelloZeroNet @shortcutme

You can add directories/files with -default prefix that will be renamed on clone.

Thanks, but I know this and already using it.

What would be you usecase?

I'm creating Framework.js, and it will have a button in header where ZeroNet users can clone the site, to create a brand new zite based on FrameworkJS.
But the site have redundant files that can only be used on its own, but not in the clonned sites.
The ZeroNet's site clone feature is amazing, but really needs more improvements.
Not only -noclone prefix is needed, but also -noupgrade, as mentioned in this new issue: #1529

I need to launch FrameworkJS in order to begin other zite projects, so those prefixes for clonning are needed for Framework work in its full, and other projects that can be benefited from those new clonning prefixes.

As mentioned in #1531:
Instead of using prefixes in file names (it will make names very ugly), site owner can add those infos in content.json.

I'm creating Framework.js, and it will have a button in header where ZeroNet users can clone the site, to create a brand new zite based on FrameworkJS.

There is a root_inner_path argument for siteClone call, where you can specify which directory you want to use as the root of the new site. For example ZeroHello use this feature to create a new, empty site: https://github.com/HelloZeroNet/ZeroHello/blob/master/js/Head.coffee#L37

I'd like to point out that even if there is the option clone_root in content.json, the noclone option could be useful where one wants to exclude just a couple of files from being clones and duplicating all the others can be seen as a waste of space and against the DRY principle.

@trenta3
Thank you too much!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

komachi picture komachi  路  56Comments

ghost picture ghost  路  53Comments

HelloZeroNet picture HelloZeroNet  路  58Comments

mx5kevin picture mx5kevin  路  34Comments

HelloZeroNet picture HelloZeroNet  路  42Comments