Feature: add scrabble resolver project

This commit is contained in:
2017-09-28 15:23:16 +02:00
parent 9cf7a6593e
commit 93e63c5560
21 changed files with 580 additions and 8 deletions

View File

@@ -2,12 +2,12 @@
"docs": [
{
"location": "/",
"text": "Welcome\n\n\nI made some projects and published them on \nGitHub\n.\nIn this space, you will find some of them. Basiclly, these pages are \nREADME\n files but with some adds and demos.\n\n\nDifferent projects for different needs :\n\n\n\n\nDevelopment\n\n\nJava\n\n\nSpringboot / React / Webpack\n\n\n\n\n\n\nNodeJS\n\n\nCloudBudget\n (Express)\n\n\nProject deployer\n (Meteor)\n\n\n\n\n\n\nClient-side\n\n\nCloudBudget-AngularJS\n (Express / AngularJS)\n\n\nDurandal filebrowser widget\n (DurandalJS)\n\n\n\n\n\n\n\n\n\n\nDocker\n\n\nFullstack servers\n\n\nLog centralizer\n ELK stack with Kafka\n\n\nGoCD\n GoCD server and agents\n\n\n\n\n\n\nUtilities\n\n\nApache log generator\n\n\nJava log generator\n\n\n\n\n\n\n\n\n\n\nJavascript games\n\n\nSpace invaders\n\n\nPacman\n\n\nPyramid\n\n\nWord Fighters\n \n\n\nYahtzee",
"text": "Welcome\n\n\nI made some projects and published them on \nGitHub\n.\nIn this space, you will find some of them. Basiclly, these pages are \nREADME\n files but with some adds and demos.\n\n\nDifferent projects for different needs :\n\n\n\n\nDevelopment\n\n\nJava\n\n\nScrabble resolver\n\n\nSpringboot / React / Webpack\n\n\n\n\n\n\nNodeJS\n\n\nCloudBudget\n (Express)\n\n\nProject deployer\n (Meteor)\n\n\n\n\n\n\nClient-side\n\n\nCloudBudget-AngularJS\n (Express / AngularJS)\n\n\nDurandal filebrowser widget\n (DurandalJS)\n\n\n\n\n\n\n\n\n\n\nDocker\n\n\nFullstack servers\n\n\nLog centralizer\n ELK stack with Kafka\n\n\nGoCD\n GoCD server and agents\n\n\n\n\n\n\nUtilities\n\n\nApache log generator\n\n\nJava log generator\n\n\n\n\n\n\n\n\n\n\nJavascript games\n\n\nSpace invaders\n\n\nPacman\n\n\nPyramid\n\n\nWord Fighters\n \n\n\nYahtzee",
"title": "Home"
},
{
"location": "/#welcome",
"text": "I made some projects and published them on GitHub .\nIn this space, you will find some of them. Basiclly, these pages are README files but with some adds and demos. Different projects for different needs : Development Java Springboot / React / Webpack NodeJS CloudBudget (Express) Project deployer (Meteor) Client-side CloudBudget-AngularJS (Express / AngularJS) Durandal filebrowser widget (DurandalJS) Docker Fullstack servers Log centralizer ELK stack with Kafka GoCD GoCD server and agents Utilities Apache log generator Java log generator Javascript games Space invaders Pacman Pyramid Word Fighters Yahtzee",
"text": "I made some projects and published them on GitHub .\nIn this space, you will find some of them. Basiclly, these pages are README files but with some adds and demos. Different projects for different needs : Development Java Scrabble resolver Springboot / React / Webpack NodeJS CloudBudget (Express) Project deployer (Meteor) Client-side CloudBudget-AngularJS (Express / AngularJS) Durandal filebrowser widget (DurandalJS) Docker Fullstack servers Log centralizer ELK stack with Kafka GoCD GoCD server and agents Utilities Apache log generator Java log generator Javascript games Space invaders Pacman Pyramid Word Fighters Yahtzee",
"title": "Welcome"
},
{
@@ -110,6 +110,36 @@
"text": "The location for deployed projects is set in the server/constants.js file with the DEPLOYMENT_FOLDER variable. To launch ProjectDeployer, use the following command : meteor --port $IP:$PORT \n Fork me on GitHub",
"title": "Usage"
},
{
"location": "/development/scrabble_resolver/",
"text": "scrabble-resolver\n\n\nThis project builds language resolvers to resolve Scrabble enigmas.\n\n\nUsage\n\n\nusage: Main [-b \nsource\n] [-h] -l \nlanguage\n [-max \nmax\n] [-min \nmin\n] [-r \nletters\n]\n -b,--build \nsource\n Build a new dictionary from the source file (a\n Linux words file)\n -h,--help Display help message\n -l,--lang \nlanguage\n Language (in [english, french])\n -max,--max \nmax\n Maximum word length (default : 7)\n -min,--min \nmin\n Minimum word length (default : 3)\n -r,--resolve \nletters\n Find words with the given letters\n\n\n\n\nThis project can be used to provide data to game such as \nWord Fighters\n.\n\n\nBuilding a resolver\n\n\nThis project comes with 2 resolvers :\n\n\n\n\nEnglish (British)\n\n\nFrench\n\n\n\n\nTo generate new ones, just use a file with one word per line (such as Linux \nwords\n) and run the Main providing the following parameters :\n\n\n\n\n--build followed by the path to the file to parse\n\n\n--lang to provide the language\n\n\n\n\nYou can configure words the will be manage by the resolver using the \n--min\n and \n--max\n parameters. Only words with length between \n--min\n and \n--max\n will be manage.\n\n\nThe resolver will be generated in the \nsrc/main/resource/resolvers\n folder. To use it, rebuild the project :\n\n\nmvn clean package\n\n\n\n\nResolving enigmas\n\n\nYou can generate and resolve engima just using the \n--lang\n parameter. A enigma will be generated and resolved using default parameters. You can custom resolution using the \n--min\n and \n--max\n parameters.\n\n\nYou can provide a letter suite to resolve using the \n--resolve\n parameter, ie :\n\n\n$\n Main -l english -r achilst\nResolver in english loaded in 388ms.\nLetters : achilst\nWords between 3 and 7 letters : \n with 5 letters (14): [chats, chits, clash, hails, halts, hilts, latch, laths, saith, shalt, staci, tails, thais, tisha]\n with 4 letters (35): [acts, ails, alit, cali, cash, cast, cats, chat, chit, hail, hals, halt, hats, hilt, hits, itch, lash, last, lath, lats, lisa, list, sail, salt, scat, shat, shit, silt, slat, slit, tail, talc, thai, this, tics]\n with 3 letters (23): [act, ail, ali, ash, ats, cal, cat, chi, hal, has, hat, his, hit, ila, its, lit, sac, sal, sat, sic, sit, tia, tic]\n\n\n\n\n\nLicences\n\n\nCopyright (c) 2017 Fabrice ECAILLE aka Febbweiss\n\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n\n\n\n\n \nFork me on GitHub",
"title": "Scrabble resolver"
},
{
"location": "/development/scrabble_resolver/#scrabble-resolver",
"text": "This project builds language resolvers to resolve Scrabble enigmas.",
"title": "scrabble-resolver"
},
{
"location": "/development/scrabble_resolver/#usage",
"text": "usage: Main [-b source ] [-h] -l language [-max max ] [-min min ] [-r letters ]\n -b,--build source Build a new dictionary from the source file (a\n Linux words file)\n -h,--help Display help message\n -l,--lang language Language (in [english, french])\n -max,--max max Maximum word length (default : 7)\n -min,--min min Minimum word length (default : 3)\n -r,--resolve letters Find words with the given letters This project can be used to provide data to game such as Word Fighters .",
"title": "Usage"
},
{
"location": "/development/scrabble_resolver/#building-a-resolver",
"text": "This project comes with 2 resolvers : English (British) French To generate new ones, just use a file with one word per line (such as Linux words ) and run the Main providing the following parameters : --build followed by the path to the file to parse --lang to provide the language You can configure words the will be manage by the resolver using the --min and --max parameters. Only words with length between --min and --max will be manage. The resolver will be generated in the src/main/resource/resolvers folder. To use it, rebuild the project : mvn clean package",
"title": "Building a resolver"
},
{
"location": "/development/scrabble_resolver/#resolving-enigmas",
"text": "You can generate and resolve engima just using the --lang parameter. A enigma will be generated and resolved using default parameters. You can custom resolution using the --min and --max parameters. You can provide a letter suite to resolve using the --resolve parameter, ie : $ Main -l english -r achilst\nResolver in english loaded in 388ms.\nLetters : achilst\nWords between 3 and 7 letters : \n with 5 letters (14): [chats, chits, clash, hails, halts, hilts, latch, laths, saith, shalt, staci, tails, thais, tisha]\n with 4 letters (35): [acts, ails, alit, cali, cash, cast, cats, chat, chit, hail, hals, halt, hats, hilt, hits, itch, lash, last, lath, lats, lisa, list, sail, salt, scat, shat, shit, silt, slat, slit, tail, talc, thai, this, tics]\n with 3 letters (23): [act, ail, ali, ash, ats, cal, cat, chi, hal, has, hat, his, hit, ila, its, lit, sac, sal, sat, sic, sit, tia, tic]",
"title": "Resolving enigmas"
},
{
"location": "/development/scrabble_resolver/#licences",
"text": "Copyright (c) 2017 Fabrice ECAILLE aka Febbweiss Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \n Fork me on GitHub",
"title": "Licences"
},
{
"location": "/development/springboot_react_webpack/",
"text": "springboot-react-webpack\n\n\nA demo project with Spring Boot, React and Webpack\n\n\nThis project includes :\n\n\n\n\nSpring Boot as backend resource\n\n\nReact as client JS framework\n\n\nwebpack to translate JSX to JS and manage client resources link\n\n\nmaven-release-plugin\n\n\ncf-maven-plugin\n\n\ndocker-maven-plugin (from Spotify)\n\n\n\n\nProfile\n\n\nThere are 3 profiles :\n\n\n\n\nthe default one (without specification) is for development mode.\n\n\nproduction\n used to generate the production ready client resources\n\n\ndocker\n to access to the Docker plugin and generate an image\n\n\n\n\nLaunching\n\n\nTo launch this project, just use the following command line :\n\n\nIn development mode :\n\n\nmvn clean spring-boot:run\nnpm run watch\n\n\n\n\nIn production mode :\n\n\nmvn clean spring-boot:run -P production\n\n\n\n\nWithout a profile, you have to run the webpack watcher to deliver client resources. With the \nproduction\n profile, no needs to launch the wepback watcher.\n\n\nConfiguration\n\n\nTo use the CloudFoundry and Release plugins, the \nsettings.xml\n must contains the following lines :\n\n\n \nservers\n\n \nserver\n\n \nid\ncloudfoundry\n/id\n\n \nusername\nusername\n/username\n\n \npassword\npassword\n/password\n\n \n/server\n\n \nserver\n\n \nid\ngithub\n/id\n\n \nusername\nusername\n/username\n\n \npassword\npassword\n/password\n\n \n/server\n\n \n/servers\n\n\n\n\n\nSpring Boot\n\n\nSpring Boot is used as the backend server. It provides the HTML pages and the REST endpoints.\nReact is server side compiled at runtime using nashorn.\n\n\nReact\n\n\nReact is the client side library. It's possible to write JSX which will be translate by webpack.\n\n\nWebpack\n\n\nConfiguration\n\n\nWebpack configuration is done by the \nwebpack.config.js\n file at the project's root.\n\n\nUsage\n\n\nWebpack is launched at the \ngenerate-resources\n maven phase.\nIn this configuration, webpack provides resources (JS and CSS) for commons librairies and custom JS scripts. It takes in account LESS. The HTML final resource is generated from a template adding the needed resources.\nUsing the default profile and the watcher, the HotModuleReplacement module is activated, so no need to refresh the page when updating a JS or a CSS, webpack does it.\n\n\nPlugin release\n\n\nConfiguration\n\n\nTo manage the release process with Git, you have to replace the link in the \ndeveloperConnection\n tag with the Git project URL.\n\n\nUsage\n\n\nThe \nmaven-release-plugin\n allows to release an app tagging the repository. A release is :\n\n changing from SNAPSHOT to stable\n\n creating a tag (locally and remotely)\n* increasing the SNAPSHOT version\n\n\nTwo steps :\n\n\nmvn release:prepare\nmvn release:perform\n\n\n\n\nTo rollback a \nprepare\n :\n\n\nmvn release:rollback\n\n\n\n\nTo test the release :\n\n\nmvn -DdryRun=true release:prepare\nmvn release:clean (test cleaning)\n\n\n\n\nDocumentation\n\n\nhttps://maven.apache.org/maven-release/maven-release-plugin/index.html\n\n\nPlugin CloudFoundry\n\n\nConfiguration\n\n\nChange the \nTOFILL\n strings in the comment plugin's section.\n\n\nUsage\n\n\nThe \ncf-maven-plugin\n plugin allows to manage the application in a CloudFoundry platform and specifically to push it :\n\n\nmvn cf:push\n\n\n\n\nDocumentation\n\n\nhttp://docs.cloudfoundry.org/buildpacks/java/build-tool-int.html\n\n\nPlugin Docker\n\n\nConfiguration\n\n\nThe \ndocker-maven-plugin\n (from Spotify) plugin has no configuration.\n\n\nUsage\n\n\nThe default project packaging (for CloudFoundry) is a WAR. In the Docker image, we use a JAR. To use this plugin (and the correct packaging), use the \ndocker\n profile :\n\n\nmvn package -P docker\n\n\n\n\nThis command generates a local Docker image. To manage it, use the \ndocker\n profile to access the \ndocker-maven-plugin\n (such as push it).\n\n\nDocumentation\n\n\nhttps://github.com/spotify/docker-maven-plugin\n\n\n\n\n\n \nFork me on GitHub",