- authenticate(credentials, remember)
- register($user)
- assignRole($user, $role)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| rules: | |
| php.interface_has_no_interface_suffix: | |
| enabled: false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if ($('.slugify').length) { | |
| $('.slugify').slug({ | |
| slug: 'slug', | |
| hide: false | |
| }); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| makeSlug = function () { | |
| var slugcontent = $this.val(); | |
| var slugcontent_hyphens = slugcontent.replace(/\s/g, '-'); | |
| var slug_no_accents = this.normalize(slugcontent_hyphens); | |
| var finishedslug = slug_no_accents.replace(/[^a-zA-Z0-9\-]/g, ''); | |
| jQuery('input.' + settings.slug).val(finishedslug.toLowerCase()); | |
| jQuery('span.' + settings.slug).text(finishedslug.toLowerCase()); | |
| } | |
| normalize = function(string) { | |
| console.log(string); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Return a normalized version of a given string. | |
| * Replace accented and derivative characters by their simple version, remove any special characters and lowercase the result. | |
| * @param {String} string | |
| * @returns {String} Normalized string | |
| */ | |
| string.normalize = function(string) { | |
| //replace accented chars | |
| //http://stackoverflow.com/questions/18123501/replacing-accented-characters-with-plain-ascii-ones | |
| var defaultDiacriticsRemovalMap = [ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # -*- mode: ruby -*- | |
| # vi: set ft=ruby : | |
| # Config Github Settings | |
| github_username = "fideloper" | |
| github_repo = "Vaprobash" | |
| github_branch = "1.2.0" | |
| github_url = "https://raw.githubusercontent.com/#{github_username}/#{github_repo}/#{github_branch}" | |
| # Server Configuration |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function ($) { | |
| "use strict"; | |
| $( document ).ready(function() { | |
| $('.jsSaveProjectDraft').on('click',function (event) { | |
| event.preventDefault(); | |
| $('.jsProjectDraftForm').trigger('updateProject'); | |
| }); | |
| // Init the jquery plugin on the form |
Pour garder le code source clair, stable et de qualité, nous allons choisir une methode de travail par Feature en gardant à l'esprit qu'à chaque instant T, UN SEUL developpeur a le droit de modifier un fichier, pour éviter le plus possible les merge conflicts
En gros, On clone le code source, on crée une branche privée par fonctionalités (login/about/contact....), on travaille sur le code, des qu'on fini on renvoit le code (commit) au serveur Git pour relecture et approbation, si c'est bon on met à jour la base, et on recommence avec de nouvelles fonctionnalités.
#Example
Un exemple de commande à éxecuter (via SSH sur la VM) lors d'un developpement d'une feature pour un projet :
- String Calculator http://osherove.com/tdd-kata-1/
- String Calculator With Interactions http://osherove.com/tdd-kata-2/
- Bowling Game Kata http://butunclebob.com/ArticleS.UncleBob.TheBowlingGameKata
- ThePrimeFactorsKata http://butunclebob.com/ArticleS.UncleBob.ThePrimeFactorsKata
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $whoops = new Whoops\Run(); | |
| $whoops->pushHandler(new Whoops\Handler\PrettyPageHandler()); | |
| // Set Whoops as the default error and exception handler used by PHP: | |
| $whoops->register(); | |
| //throw new RuntimeException("Oopsie!"); |