{"id":19478444,"url":"https://github.com/firstwiki/_scripts","last_synced_at":"2025-02-25T16:41:27.135Z","repository":{"id":69908751,"uuid":"56561704","full_name":"firstwiki/_scripts","owner":"firstwiki","description":"Useful scripts for managing firstwiki","archived":false,"fork":false,"pushed_at":"2018-05-12T06:52:40.000Z","size":19,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-08T06:46:33.772Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/firstwiki.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-04-19T03:28:46.000Z","updated_at":"2019-02-04T06:09:59.000Z","dependencies_parsed_at":"2023-05-25T07:45:17.295Z","dependency_job_id":null,"html_url":"https://github.com/firstwiki/_scripts","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstwiki%2F_scripts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstwiki%2F_scripts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstwiki%2F_scripts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstwiki%2F_scripts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/firstwiki","download_url":"https://codeload.github.com/firstwiki/_scripts/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240709513,"owners_count":19845037,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T19:49:51.003Z","updated_at":"2025-02-25T16:41:27.113Z","avatar_url":"https://github.com/firstwiki.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"FIRSTwiki management scripts\n============================\n\nThis is a repository of scripts useful for doing local development on\nFIRSTwiki. Most users probably don't want to use these.. but you never\nknow.\n\nCurrently, local development using these scripts on Windows is not\nsupported. It'll probably work with msys2 or git for windows bash\nenvironment, but I haven't tried it.\n\nSetup (OSX/Linux)\n=================\n\nFirst, ensure that ruby is installed, you will probably want to use RVM (See\nhttps://rvm.io/rvm/install for details).\n\nInstall the required ruby packages\n\n\tgem install bundler\n\tbundle install\n\nCreate a directory for your wiki stuff\n\n\tmkdir wiki\n\tcd wiki\n\nClone this scripts repository into it\n\n\tgit clone https://github.com/firstwiki/_scripts\n\nRun './init_env.sh' to clone all repos and setup the environment\n\n\tcd _scripts\n\t./init_env.sh\n\nUsage\n=====\n\nYou can use ./dev.sh to do a lot of things on all of the repos at once! For example, to update all of your repos:\n\n\t./dev.sh pull\n\nOr to build all sites:\n\n\t./dev.sh build\n\nTo serve an individual site locally, you can use jekyll to do this. Each repo has\n'run_server.sh' script that will do this:\n\n\tcd wiki\n\t./run_server.sh\n\nTo serve all of the sites at the same time, then use this (requires all sites to\nbe built first!)\n\n\t./dev.sh serve_site\n\nIf you wish jekyll to watch the files and autoregenerate them when serving the\nsite, this will launch all of the sites and watch them:\n\n\t./dev.sh serve_site --watch\n\nModifying _common\n-----------------\n\n`_common` is a special repository that all of the repositories share, so it's\nset up as a git submodule so that the code doesn't need to be copied to\neach of them. However, that makes it annoying to do local development when\nyou want to change it and test on all of the repos. What you can do is use\nsymlinks so that each repository is working on the same directory -- and then\nwhen it's time to commit, you can roll back to the submodule. The workflow\nis something roughly like this.\n\nSet up the symlinks:\n\n\t./dev.sh link\n\nMake your changes to common, then do a commit there:\n\n\tcd _common\n\tgit commit -a \n\tcd ..\n\nRestore the git submodules (required to commit)\n\n\t./dev.sh unlink\n\nUpdating _common across all repos\n---------------------------------\n\n**Note**: Normal users should not do this. Instead, fork/commit to _common,\nand once your PR is accepted then an adminstrator will update all\nrepositories for you using these steps.\n\nIf you are a FIRSTwiki administrator (not a moderator), you can update\nall repos with the latest version of _common by doing the following:\n\n\t./dev.sh unlink\n\t./dev.sh update\n\nRunning the server without admin privlidges\n-------------------------------------------\n\n**Note**: These instructions were developed on mac, and instructions may differ on other platforms\n\nWithout admin rights, you cannot add new gems (such as Bundler) to the Ruby installation. If you already have bundler installed on your system, you can go ahead and skip this. If you don't, you'll need to install [RVM](https://rvm.io) (Ruby Version Manager). You can do so simply using the two commands:\n\n\tgpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3\n\t\\curl -sSL https://get.rvm.io | bash -s stable\n\nYou'll need to install `gpg` if you don't have it installed already. The first command adds the public key for the install server, and the second actually downloads and runs the install script. Double check RVM was installed by running the following command after opening a new terminal session:\n\n\ttype rvm | head -1\n\t\nIf you get `rvm is a function`, RVM was successfully installed. RVM, by default, does not actually have any copy of Ruby installed, so you'll need to install it:\n\n\trvm install ruby-head\n\t\nThis will install the latest stable version of ruby (in this case 2.2.4, it'll output the vesion when installing it). It'll go ahead and install ruby and the required gems. Next, you'll need to make sure you're using the RVM ruby and not the system ruby, as we don't have access to edit the system ruby. Run the following command to see which ruby you are running:\n\n\twhich ruby\n\t\nIf you get `.rvm` somewhere in the path, you are using the RVM ruby. If it says you are using the system ruby, run the following command to switch to the rvm ruby you just installed:\n\n\trvm use 2.2.4\n\t\nFrom here, you can now install `bundler` and follow the instructions listed at the top of this document. I created my own shell script and added the following at the top of it to make sure it loaded the correct ruby: (I installed 2.3.0 instead of 2.2.4)\n\n\tsource ~/.rvm/scripts/rvm\n\trvm use 2.3.0\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirstwiki%2F_scripts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffirstwiki%2F_scripts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirstwiki%2F_scripts/lists"}