Giter Club home page Giter Club logo

pandamd's Introduction

PandaMD

PandaMD is an application that converts markdown files in report in pdf format.

Installation

Pandoc

wget https://github.com/jgm/pandoc/releases/download/2.4/pandoc-2.4-1-amd64.deb
sudo dpkg -i pandoc-2.4-1-amd64.deb
rm pandoc-2.4-1-amd64.deb

Texlive

sudo apt install texlive-full

Template for pandoc

cd /usr/share/pandoc/data/templates
sudo wget https://raw.githubusercontent.com/steven-jeanneret/dotFiles/master/pandoc/eisvogel.latex

PandaMD

We need to give write permission to the user who will execute the queue worker.

git clone https://github.com/HE-Arc/PandaMD.git
cd PandaMD
sudo chmod a+w storage/app -R
composer install
npm install
php artisan migrate
php artisan db:seed #Only if we want default data

Queue manager

Converting markdown to pdf takes time so we make this in a queue in background.

Run on server

We will configure sv, he makes sure that the queue will always turns.

Create /etc/service/laravel-queue-worker/run with the following content :

#!/bin/sh
set -xe
cd /var/www/PandaMD
exec 2>&1
exec chpst -uwww-data php artisan queue:work
sudo chmod a+x run
sudo sv start laravel-queue-worker

Run on local

php artisan queue:work

Imgur API

When drag and dropping an image onto the editor, the image is uploaded on imgur and referenced into the editor. In order to use the API, a client ID is required. To get an Imgur client ID, it is necessary to register to Imgur. The detailed steps can be found in Imgur API reference.

When in possession of a client ID, please add the following line to your .env file:

IMGUR_CLIENT_ID=[your_client_id]

Test

Requirements

Server

Create .env.testing with the following content :

DB_SCHEMA=test

Create Schema test in database

Local

Copy .env in .env.testing and change the schema of the DB.

Before running test

php artisan config:clear
php artisan migrate --seed --env=testing

Run test

Linux:

./vendor/bin/phpunit

Windows:

"./vendor/bin/phpunit"

pandamd's People

Contributors

steven-jeanneret avatar lewisjaggi avatar haldenwat avatar

Stargazers

Bastien Wermeille avatar

Watchers

James Cloos avatar  avatar  avatar

pandamd's Issues

Upgrading edit mode

  • Change in which folder is the file
  • Change secrutiy of the file (lock icon?)
  • Add author, (multiline string?)
  • Stick the simplemde toolbar to the top

Authorize other user to edit a folder

  • Authorize all user to edit a folder (add files or folders)
  • Authorize only certain user to access to a folder
  • Authorize only certain user to access to a file

Search for user account

  • Search for user account
  • Possibility to follow an account
  • View his folders/files
  • User activity (last modified/added file of all followed account)
  • Profile pictures from gravatar

Problem bad date format

The date format is not the same. JS/PHP : dd/mm/YY, SQL : mm/dd/YY
Bug when day is greater than 12.

Move file in folder

  • Save file in a specific folder (default actual folder) dropdown with a tree of folders

Edit markdown note

  • Add an edit button who bring to a form where we can edit the markdown note.
  • Use simplemde to add tools for markdown editing
  • Include latex support in preview

Config server

See to make APP_KEY proper
See to make pandoc template path proper

Search on file

Search by title and/or by content

  • in a folders
  • in followed users
  • in all users (public files)

Add yaml options for pandoc

  • is a title page
  • is a toc
  • is the toc on his own page
  • are links as notes
  • title
  • subtitle
  • school
  • date
  • collapsible options div

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.