Giter Site home page Giter Site logo

schollz / cowyo Goto Github PK

View Code? Open in Web Editor NEW
922.0 19.0 69.0 16.74 MB

A feature-rich wiki webserver for minimalists :cow: :speech_balloon:

Home Page: https://cowyo.com/

License: MIT License

Makefile 0.73% Go 25.71% Dockerfile 0.18% CSS 7.38% JavaScript 65.69% Python 0.31%
wiki server minimalist pastebin encryption

cowyo's Introduction

linkcrawler
Build Status Version

A feature-rich wiki for minimalists

cowyo is a self-contained wiki server that makes jotting notes easy and fast. The most important feature here is simplicity. Other features include versioning, page locking, self-destructing messages, encryption, and listifying. You can download cowyo as a single executable or install it with Go. Try it out at https://cowyo.com.

There is now a command-line tool, cowyodel to interact with cowyo and transfer information between computers with only a code phrase: schollz/cowyodel.

Getting Started

Install

If you have go

go get -u github.com/schollz/cowyo/...

or just download the latest release.

Run

To run just double click or from the command line:

cowyo

and it will start a server listening on 0.0.0.0:8050. To view it, just go to http://localhost:8050 (the server prints out the local IP for your info if you want to do LAN networking). You can change the port with -port X, and you can listen only on localhost using -host localhost.

Running with TLS

Specify a matching pair of SSL Certificate and Key to run cowyo using https. cowyo will now run in a secure session.

N.B. Let's Encrypt is a CA that signs free and signed certificates.

cowyo --cert "/path/to/server.crt" --key "/p/t/server.key"

Running with Docker

You can easily get started with Docker. First pull the latest image and create the volume with:

docker run -d -v /directory/to/data:/data -p 8050:8050 schollz/cowyo

Then you can stop it with docker stop cowyo and start it again with docker start cowyo.

Server customization

There are a couple of command-line flags that you can use to make cowyo your own micro-CMS.

cowyo -lock 123 -default-page index.html -css mystyle.css -diary

The -lock flag will automatically lock every page with the passphrase "123". Also, the default behavior will be to redirect / to /index.html. Also, every page that is published will automatically redirect to /mypage/read which will show the custom CSS file if it is supplied with -css. The -diary flag allows you to generate a time-stamped page instead of a random named page when you select "New".

Usage

cowyo is straightforward to use. Here are some of the basic features:

Publishing

If you hover the the top left button (the name of the page) you will see the option "Publish". Publishing will add the page to the sitemap.xml for crawlers to find. It will also default that page to go to the /read route so it can be easily viewed as a single page.

View all the pages

To view the current list of all the pages goto to /ls.

Editing

When you open a document you'll be directed to an alliterative animal (which is supposed to be easy to remember). You can write in Markdown. Saving is performed as soon as you stop writing. You can easily link pages using [[PageName]] as you edit.

Editing

History

You can easily see previous versions of your documents.

History

Lists

You can easily make lists and check them off.

Lists

Locking

Locking prevents other users from editing your pages without a passphrase.

Locking

Encryption

Encryption is performed using AES-256.

Encryption

Self-destructing pages

Just like in mission impossible.

Self-destructing

Development

You can run the tests using

$ cd $GOPATH/src/github.com/schollz/cowyo
$ go test ./...

Any contributions are welcome.

Thanks

...to DanielHeath who has introduced some stellar improvements into cowyo including supporting category pages, hot-template reloading, preventing out-of-order updates, added password access, fade-out on deleting list items, and image upload support!

License

MIT

cowyo's People

Contributors

danielheath avatar gitter-badger avatar katomaso avatar schollz avatar silvus avatar tgulacsi avatar yamilurbina avatar zealotree avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cowyo's Issues

Admin page1

List Title (with link), number of current characters, number of changes, last updated, and the total size on disk (changes + currentText)

Also use /viewall or something

Use Markdown

| Title | Content size    | Changes  | Total Size |
| --------- |-------------| -----| ------------- |
| col 3 is      | right-aligned | $1600 | 0 |

Password protection / page locking

I think password protection could be done like this:

In an editable page a user can leave a special line, like

<user=zack password=123 public=true>

which has the advantage of not being rendered because its not valid HTML (all invalid HTML is removed on server rendering).

When this is saved into the server, the server will no longer allow anyone to enter the edit page or /list page. Instead it will always redirect to the /view page. If public=false is set, then the /view page can redirect to a password form for login. If public=true is set, then the /view page will display normally. In both cases, once the /view page is rendered, the "Edit" button should change to "Edit (with password)", which on click, asks for a password so that the user can go back to edit their page.

Page refreshes before I can save, encrypt, or use any options

Page refreshes before I can save, encrypt, or use any options

  • I go to https://cowyo.com which generates/adds random words to the URL (e.g. ConspiracyMonkey)
  • When the page generates and I start typing over the words: "Start typing it will save automatically."
  • I type anything lets say the time or date with or without a period at the end of the sentence
  • I then navigate to the bottom EDIT/SAVE menu to select any of the options (Encrypt, Lock, etc.)
  • The page refreshes automatically and without prompting :(
  • The same URL remains but none of the content wasn't saved automatically

Issue happens to me in IE and CHROME.

Roadmap to v1.0

Features in v1.0:

  • Uploading from curl (PUT request)
  • Importing from local folder
  • Better help documentation
  • Fix .html problem
  • Add more syntax highlights
  • Add documentation
  • Add view for code...just restart a that's not editable
  • new route /cdn for hosting. Fix cors and make sure version parameter still works
  • Mobile width is weird
  • Specify version in edit menu
  • CodeMirror needs to have box (so you can see where text is left off on the right edge)

Notice for passwords

For locking... Note password is stored on server.

For encryption.... Note passwords are not stored on server and original text cannot be recovered if password is lost. Also version history will also be destroyed.

For erasing. All versions will be removed and cannot be recovered.

Syntax highlighting

  • Fix .html problem
  • Add more syntax highlights
  • Add documentation
  • Add view for code...just restart a that's not editable
  • new route /cdn for hosting. Fix cors and make sure version parameter still works
  • Mobile width is weird
  • Specify version in edit menu

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.