├── .gitignore ├── convert-to-pdf.js ├── package.json ├── readme.md └── usage.md /.gitignore: -------------------------------------------------------------------------------- 1 | readme.pdf 2 | package-lock.json 3 | node_modules 4 | -------------------------------------------------------------------------------- /convert-to-pdf.js: -------------------------------------------------------------------------------- 1 | const convertToPDF = require('markdown-pdf'); 2 | const through2 = require('through2'); 3 | const prompt = require('prompt'); 4 | 5 | const extra = ` 6 | ## The Less Quick Version 7 | 8 | Read the full Code of Conduct at **github.com/ReactVienna/code-of-conduct**! 9 | ` 10 | 11 | const convert = (phones) => { 12 | console.log('Starting conversion to PDF...'); 13 | convertToPDF({ 14 | preProcessMd: () => through2(function (chunk, enc, callback) { 15 | const string = chunk.toString(); 16 | // Cut everything after "The less quick version" 17 | let short = string.substring(0, string.indexOf('The Less Quick Version')); 18 | short = `${short}${extra}` 19 | if (phones && phones.length > 0 && phones.every(data => data.name && data.phone)) { 20 | // Insert phone numbers 21 | const text = "There'll always be at least one of them at any ReactVienna-sponsored space."; 22 | const index = short.indexOf(text); 23 | const before = short.substring(0, index); 24 | const after = short.substring(index); 25 | const numbers = `You can also call them:\n${phones.map(data => `- ${data.name}: ${data.phone}`).join('\n')}\n\n`; 26 | this.push(before + numbers + after); 27 | } else { 28 | console.warn('No phone numbers provided, please provide at least one phone number if possible.') 29 | this.push(short); 30 | } 31 | callback(); 32 | }), 33 | }).from('./readme.md').to('./readme.pdf', () => { 34 | console.log('Conversion to PDF finished, check readme.pdf'); 35 | }); 36 | } 37 | 38 | const schema = { 39 | properties: { 40 | name: { 41 | description: 'Enter the full name of an organizer. (e.g. Max Mustermann)' 42 | }, 43 | phone: { 44 | description: 'Enter their phone number, including country code (e.g. +43 664 1231231).' 45 | }, 46 | more: { 47 | description: 'Do you want to add another phone number? ("true" or "false")', 48 | type: 'boolean' 49 | } 50 | } 51 | }; 52 | 53 | const phones = []; 54 | 55 | const askForPhone = () => { 56 | prompt.get(schema, (err, result) => { 57 | if (err) return console.error('\n\nError:', err.message); 58 | 59 | phones.push(result); 60 | 61 | if (result.more) { 62 | askForPhone(); 63 | } else { 64 | convert(phones); 65 | } 66 | }) 67 | } 68 | 69 | prompt.start(); 70 | askForPhone(); 71 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "code-of-conduct", 3 | "version": "1.0.0", 4 | "description": "All attendees, speakers, sponsors and volunteers at our meetup are required to agree with the following code of conduct. Organisers will enforce this code throughout the event. We expect cooperation from all participants to help ensure a safe environment for everybody.", 5 | "main": "convert-to-pdf.js", 6 | "dependencies": { 7 | "markdown-pdf": "^8.0.0", 8 | "prompt": "^1.0.0", 9 | "through2": "^2.0.3" 10 | }, 11 | "devDependencies": {}, 12 | "scripts": { 13 | "convert": "node ./convert-to-pdf.js" 14 | }, 15 | "repository": { 16 | "type": "git", 17 | "url": "git+https://github.com/reactvienna/code-of-conduct.git" 18 | }, 19 | "author": "", 20 | "license": "MIT", 21 | "bugs": { 22 | "url": "https://github.com/reactvienna/code-of-conduct/issues" 23 | }, 24 | "homepage": "https://github.com/reactvienna/code-of-conduct#readme" 25 | } 26 | -------------------------------------------------------------------------------- /readme.md: -------------------------------------------------------------------------------- 1 | # ReactVienna Code of Conduct 2 | 3 | All attendees, speakers, sponsors and volunteers at our meetup are required to agree with the following code of conduct. Organisers will enforce this code throughout the event. We expect cooperation from all participants to help ensure a safe environment for everybody. 4 | 5 | This code of conduct applies to all ReactVienna-sponsored spaces, including our meetups, communication channels (eg. Slack), parties and other spaces that ReactVienna hosts, both online and offline. 6 | 7 | Some of these spaces may have additional rules in place, which will be made clearly available to participants. Participants are responsible for knowing and abiding by these rules. 8 | 9 | ## Need Help? 10 | 11 | Contact one of the meetup organisers immediately: 12 | 13 | - **Max Stoiber (contact@mxstbr.com)** 14 | - Juho Vepsäläinen (bebraw@gmail.com) 15 | - Nik Graf (nik@nikgraf.com) 16 | - Andrey Okonetchnikov (andrey@okonet.ru) 17 | - Glenn Reyes (glenn@glennreyes.com) 18 | - Karl Horky (karl.horky@gmail.com) 19 | - Patrick Ecker (hi@ryyppy.com) 20 | - Carmen Huidobro (hola@carmenh.dev) 21 | 22 | There'll always be at least one of them at any ReactVienna-sponsored space. 23 | 24 | There is also a **point of contact outside of the organiser group** in case you don't feel comfortable reaching out to them: Laura Gaetano, who works at TravisCI and organises the Rails Girls Summer of Code. (laura@travis-ci.org) 25 | 26 | ## Our Standards 27 | 28 | Examples of behavior that contributes to a positive environment for our community include: 29 | 30 | - Demonstrating empathy and kindness toward other people 31 | - Being respectful of differing opinions, viewpoints, and experiences 32 | - Giving and gracefully accepting constructive feedback 33 | - Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience 34 | - Focusing on what is best not just for us as individuals, but for the overall community 35 | 36 | ## The Quick Version 37 | 38 | Our meetup is dedicated to providing a harassment-free meetup experience for everyone, regardless of gender, gender identity and expression, age, sexual orientation, disability, physical appearance, body size, race, ethnicity, religion (or lack thereof), or technology choices. We do not tolerate harassment of meetup participants in any form. Sexual language and imagery is not appropriate for any meetup venue, including talks, workshops, parties, Twitter and other online media. Meetup participants violating these rules may be sanctioned or expelled from the meetup at the discretion of the organisers. 39 | 40 | ## The Less Quick Version 41 | 42 | Harassment includes offensive verbal comments related to gender, gender identity and expression, age, sexual orientation, disability, physical appearance, body size, race, ethnicity, religion, technology choices, sexual images in public spaces, deliberate intimidation, stalking, following, harassing photography or recording, sustained disruption of talks or other events, inappropriate physical contact, and unwelcome sexual attention. This includes any other conduct which could reasonably be considered inappropriate in a professional setting. 43 | 44 | Participants asked to stop any harassing behavior are expected to comply immediately. 45 | 46 | Sponsors are also subject to the anti-harassment policy. In particular, sponsors should not use sexualised images, activities, or other material. 47 | 48 | If a participant engages in harassing or other inappropriate behavior, the meetup organisers may take any action they deem appropriate, including warning the offender or expulsion from the meetup. 49 | 50 | If you are being harassed, notice that someone else is being harassed, or have any other concerns, please contact a member of the meetup organisers immediately via the contact details provided above. 51 | 52 | The organisers will be happy to help participants contact venue security or local law enforcement, provide escorts, or otherwise assist those experiencing harassment to feel safe for the duration of the meetup. We value your attendance. 53 | 54 | ## Acknowledgements 55 | 56 | This Code of Conduct is adapted from the [Conf Code of Conduct](http://confcodeofconduct.com/), which itself is based on the [2012 JSConf Code of Conduct](http://2012.jsconf.us/#/about) and [The Ada Initiative](http://geekfeminism.wikia.com/wiki/Conference_anti-harassment/Policy). Phrasing from the [Contributor Covenant](https://www.contributor-covenant.org/version/2/0/code_of_conduct/) is also included. 57 | 58 | ## License 59 | 60 | This Code of Conduct is licensed under the [Creative Commons Attribution 3.0 Unported License](https://creativecommons.org/licenses/by/3.0/deed.en_US). 61 | 62 | -------------------------------------------------------------------------------- /usage.md: -------------------------------------------------------------------------------- 1 | # Usage 2 | 3 | Since we want folks who want to complain to do so asap, we have to add phone numbers to the contact information. We don't want to put our phone numbers into the public though, so we don't host them in this repo. 4 | 5 | Instead, there is a utility function which prompts for phone numbers, inserts them into the text and converts the CoC to PDF for printing for the events. 6 | 7 | To run it: 8 | 9 | ```sh 10 | # Only need to this once 11 | npm install 12 | 13 | # Convert the readme 14 | npm run convert 15 | ``` 16 | 17 | It will prompt you for as many phone numbers as you would like to add, and ouput `readme.pdf` ready for printing. 18 | --------------------------------------------------------------------------------