From 3b738d58f036aec73f6d4c86de259d7cdf701152 Mon Sep 17 00:00:00 2001 From: Aviral Verma Date: Mon, 5 Jun 2017 10:12:16 +0530 Subject: [PATCH 1/7] fixed bold name error in some templates --- .../generator/templates/template2/index.js | 9 +- .../generator/templates/template2/index.js~ | 268 ++++++++++++++ .../generator/templates/template4/index.js | 7 +- .../generator/templates/template4/index.js~ | 335 ++++++++++++++++++ .../generator/templates/template6/index.js | 7 +- .../generator/templates/template6/index.js~ | 214 +++++++++++ 6 files changed, 824 insertions(+), 16 deletions(-) create mode 100644 app/server/src/generator/templates/template2/index.js~ create mode 100644 app/server/src/generator/templates/template4/index.js~ create mode 100644 app/server/src/generator/templates/template6/index.js~ diff --git a/app/server/src/generator/templates/template2/index.js b/app/server/src/generator/templates/template2/index.js index 63002345..df0b788d 100644 --- a/app/server/src/generator/templates/template2/index.js +++ b/app/server/src/generator/templates/template2/index.js @@ -32,12 +32,9 @@ function generateProfileSection(profile) { if (names.length === 1) { nameStart = names[0] - } else if (names.length === 2) { - nameStart = names[0] - nameEnd = names[1] - } else { - nameStart = names.slice(0, names.length - 1).join(' ') - nameEnd = names[names.length - 1] + } else { + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') } nameLine = `\\headerfirstnamestyle{${nameStart}} \\headerlastnamestyle{${nameEnd}} \\\\` diff --git a/app/server/src/generator/templates/template2/index.js~ b/app/server/src/generator/templates/template2/index.js~ new file mode 100644 index 00000000..df0b788d --- /dev/null +++ b/app/server/src/generator/templates/template2/index.js~ @@ -0,0 +1,268 @@ +const { stripIndent, source } = require('common-tags') +const { WHITESPACE } = require('../constants') + +function template2({ profile, schools, jobs, projects, skills, awards }) { + return stripIndent` + ${generateHeader()} + \\begin{document} + ${generateProfileSection(profile)} + ${generateEducationSection(schools)} + ${generateExperienceSection(jobs)} + ${generateSkillsSection(skills)} + ${generateProjectsSection(projects)} + ${generateAwardsSection(awards)} + ${WHITESPACE} + \\end{document} + ` +} + +function generateProfileSection(profile) { + if (!profile) { + return '' + } + + const { fullName, email, phoneNumber, address, link } = profile + + let nameLine = '' + + if (fullName) { + const names = fullName.split(' ') + let nameStart = '' + let nameEnd = '' + + if (names.length === 1) { + nameStart = names[0] + } else { + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') + } + + nameLine = `\\headerfirstnamestyle{${nameStart}} \\headerlastnamestyle{${nameEnd}} \\\\` + } + + const emailLine = email ? `{\\faEnvelope\\ ${email}}` : '' + const phoneLine = phoneNumber ? `{\\faMobile\\ ${phoneNumber}}` : '' + const addressLine = address ? `{\\faMapMarker\\ ${address}}` : '' + const linkLine = link ? `{\\faLink\\ ${link}}` : '' + const info = [emailLine, phoneLine, addressLine, linkLine] + .filter(Boolean) + .join(' | ') + + return stripIndent` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % Profile + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\begin{center} + ${nameLine} + \\vspace{2mm} + ${info} + \\end{center} + ` +} + +function generateEducationSection(schools) { + if (!schools) { + return '' + } + + return source` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % Education + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\cvsection{Education} + \\begin{cventries} + ${schools.map(school => { + const { name, location, degree, major, gpa, graduationDate } = school + + let degreeLine = '' + + if (degree && major) { + degreeLine = `${degree} in ${major}` + } else if (degree || major) { + degreeLine = degree || major + } + + return stripIndent` + \\cventry + {${degreeLine}} + {${name || ''}} + {${location || ''}} + {${graduationDate || ''}} + {${gpa ? `GPA: ${gpa}` : ''}} + ` + })} + \\end{cventries} + + \\vspace{-2mm} + ` +} + +function generateExperienceSection(jobs) { + if (!jobs) { + return '' + } + + return source` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % Experience + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\cvsection{Experience} + \\begin{cventries} + ${jobs.map(job => { + const { name, title, location, startDate, endDate, duties } = job + + let dateRange = '' + let dutyLines = '' + + if (startDate && endDate) { + dateRange = `${startDate} – ${endDate}` + } else if (startDate) { + dateRange = `${startDate} – Present` + } else { + dateRange = endDate + } + + if (duties) { + dutyLines = source` + \\begin{cvitems} + ${duties.map(duty => `\\item {${duty}}`)} + \\end{cvitems} + ` + } + + return stripIndent` + \\cventry + {${title || ''}} + {${name || ''}} + {${location || ''}} + {${dateRange}} + {${dutyLines}} + ` + })} + \\end{cventries} + ` +} + +function generateSkillsSection(skills) { + if (!skills) { + return '' + } + + return source` + \\cvsection{Skills} + \\begin{cventries} + \\cventry + {} + {\\def\\arraystretch{1.15}{\\begin{tabular}{ l l } + ${skills.map(skill => { + const { name, details } = skill + const nameLine = name ? `${name}: ` : '' + const detailsLine = `{\\skill{ ${details || ''}}}` + + return `${nameLine} & ${detailsLine} \\\\` + })} + \\end{tabular}}} + {} + {} + {} + \\end{cventries} + + \\vspace{-7mm} + ` +} + +function generateProjectsSection(projects) { + if (!projects) { + return '' + } + + return source` + \\cvsection{Projects} + \\begin{cventries} + ${projects.map(project => stripIndent` + \\cventry + {${project.description || ''}} + {${project.name || ''}} + {${project.technologies || ''}} + {${project.link || ''}} + {} + + \\vspace{-5mm} + + `)} + \\end{cventries} + ` +} + +function generateAwardsSection(awards) { + if (!awards) { + return '' + } + + return source` + \\cvsection{Honors \\& Awards} + \\begin{cvhonors} + ${awards.map(award => { + const { name, details, date, location } = award + + return stripIndent` + \\cvhonor + {${name || ''}} + {${details || ''}} + {${location || ''}} + {${date || ''}} + ` + })} + \\end{cvhonors} + ` +} + +function generateHeader() { + return stripIndent` + %!TEX TS-program = xelatex + %!TEX encoding = UTF-8 Unicode + % Awesome CV LaTeX Template + % + % This template has been downloaded from: + % https://github.com/posquit0/Awesome-CV + % + % Author: + % Claud D. Park + % http://www.posquit0.com + % + % Template license: + % CC BY-SA 4.0 (https://creativecommons.org/licenses/by-sa/4.0/) + % + + + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % Configuration + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + %%% Themes: Awesome-CV + \\documentclass[]{awesome-cv} + \\usepackage{textcomp} + %%% Override a directory location for fonts(default: 'fonts/') + \\fontdir[fonts/] + + %%% Configure a directory location for sections + \\newcommand*{\\sectiondir}{resume/} + + %%% Override color + % Awesome Colors: awesome-emerald, awesome-skyblue, awesome-red, awesome-pink, awesome-orange + % awesome-nephritis, awesome-concrete, awesome-darknight + %% Color for highlight + % Define your custom color if you don't like awesome colors + \\colorlet{awesome}{awesome-red} + %\\definecolor{awesome}{HTML}{CA63A8} + %% Colors for text + %\\definecolor{darktext}{HTML}{414141} + %\\definecolor{text}{HTML}{414141} + %\\definecolor{graytext}{HTML}{414141} + %\\definecolor{lighttext}{HTML}{414141} + + %%% Override a separator for social informations in header(default: ' | ') + %\\headersocialsep[\\quad\\textbar\\quad] + ` +} + +module.exports = template2 diff --git a/app/server/src/generator/templates/template4/index.js b/app/server/src/generator/templates/template4/index.js index 727eb997..670fbe91 100644 --- a/app/server/src/generator/templates/template4/index.js +++ b/app/server/src/generator/templates/template4/index.js @@ -34,12 +34,9 @@ function generateProfileSection(profile) { if (names.length === 1) { nameStart = names[0] nameEnd = '' - } else if (names.length === 2) { - nameStart = names[0] - nameEnd = names[1] } else { - nameStart = names.slice(0, names.length - 1).join(' ') - nameEnd = names[names.length - 1] + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') } } diff --git a/app/server/src/generator/templates/template4/index.js~ b/app/server/src/generator/templates/template4/index.js~ new file mode 100644 index 00000000..670fbe91 --- /dev/null +++ b/app/server/src/generator/templates/template4/index.js~ @@ -0,0 +1,335 @@ +const { stripIndent, source } = require('common-tags') +const { WHITESPACE } = require('../constants') + +function template4({ profile, schools, jobs, projects, skills, awards }) { + return stripIndent` + ${generateCommentHeader()} + \\documentclass[]{deedy-resume-openfont} + + \\begin{document} + ${generateProfileSection(profile)} + ${generateEducationSection(schools)} + ${generateExperienceSection(jobs)} + ${generateSkillsSection(skills)} + ${generateProjectsSection(projects)} + ${generateAwardsSection(awards)} + ${WHITESPACE} + \\end{document} + ` +} + +function generateProfileSection(profile) { + if (!profile) { + return '\\namesection{Your}{Name}{}' + } + + const { fullName, email, phoneNumber, address, link } = profile + + let nameStart = '' + let nameEnd = '' + + if (fullName) { + const names = fullName.split(' ') + + if (names.length === 1) { + nameStart = names[0] + nameEnd = '' + } else { + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') + } + } + + const info = [email, phoneNumber, address, link].filter(Boolean).join(' | ') + + const sectionHeader = stripIndent` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % Profile + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + ` + + if (!fullName) { + return stripIndent` + ${sectionHeader} + \\centering{ + \\color{headings} + \\fontspec[Path = fonts/raleway/]{Raleway-Medium} + \\fontsize{11pt}{14pt} + \\selectfont ${info} + } + ` + } + + return stripIndent` + ${sectionHeader} + \\namesection{${nameStart}}{${nameEnd}}{${info}} + ` +} + +function generateEducationSection(schools) { + if (!schools) { + return '' + } + + return source` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % Education + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\section{Education} + \\raggedright + ${schools.map(school => { + const { name, location, degree, major, gpa, graduationDate } = school + + let line1 = '' + let line2 = '' + + if (name) { + line1 += `\\runsubsection{${name}}` + } + + if (degree && major) { + line1 += `\\descript{| ${degree} ${major}}` + } else if (degree) { + line1 += `\\descript{| ${degree}}` + } else if (major) { + line1 += `\\descript{| ${major}}` + } + + const locationAndDate = [location, graduationDate] + .filter(Boolean) + .join(' | ') + + if (locationAndDate) { + line1 += `\\hfill \\location{${locationAndDate}}` + } + + if (line1) { + line1 += '\\\\' + } + + if (gpa) { + line2 += `GPA: ${gpa}\\\\` + } + + return ` + ${line1} + ${line2} + \\sectionsep + ` + })} + ` +} + +function generateExperienceSection(jobs) { + if (!jobs) { + return '' + } + + return source` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % Experience + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\section{Experience} + ${jobs.map(job => { + const { name, title, location, startDate, endDate, duties } = job + + let line1 = '' + let dateRange = '' + let dutyLines = '' + + if (name) { + line1 += `\\runsubsection{${name}}` + } + + if (title) { + line1 += `\\descript{| ${title}}` + } + + if (startDate && endDate) { + dateRange = `${startDate} – ${endDate}` + } else if (startDate) { + dateRange = `${startDate} – Present` + } else { + dateRange = endDate + } + + if (location && dateRange) { + line1 += `\\hfill \\location{${location} | ${dateRange}}` + } else if (location) { + line1 += `\\hfill \\location{${location}}` + } else if (dateRange) { + line1 += `\\hfill \\location{${dateRange}}` + } + + if (duties) { + dutyLines = source` + \\begin{tightemize} + ${duties.map(duty => `\\item ${duty}`)} + \\end{tightemize} + ` + } + + return stripIndent` + ${line1} + ${dutyLines} + \\sectionsep + ` + })} + ` +} + +function generateSkillsSection(skills) { + if (!skills) { + return '' + } + + return source` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % Skills + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\section{Skills} + \\raggedright + \\begin{tabular}{ l l } + ${skills.map(skill => `\\descript{${skill.name}} & {\\location{${skill.details}}} \\\\`)} + \\end{tabular} + \\sectionsep + ` +} + +function generateProjectsSection(projects) { + if (!projects) { + return '' + } + + return source` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % Projects + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\section{Projects} + \\raggedright + ${projects.map(project => { + const { name, description, technologies, link } = project + + let line1 = '' + let line2 = '' + let line3 = '' + + if (name) { + line1 += `\\runsubsection{\\large{${name}}}` + } + + if (technologies) { + line2 += `\\descript{| ${technologies}}` + } + + if (link) { + line2 += `\\hfill \\location{${link}}` + } + + if (line2) { + line2 += '\\\\' + } + + if (description) { + line3 += `${description}\\\\` + } + + return ` + ${line1} + ${line2} + ${line3} + \\sectionsep + ` + })} + ` +} + +function generateCommentHeader() { + return stripIndent` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % This is a modified ONE COLUMN version of + % the following template: + % + % Deedy - One Page Two Column Resume + % LaTeX Template + % Version 1.1 (30/4/2014) + % + % Original author: + % Debarghya Das (http://debarghyadas.com) + % + % Original repository: + % https://github.com/deedydas/Deedy-Resume + % + % IMPORTANT: THIS TEMPLATE NEEDS TO BE COMPILED WITH XeLaTeX + % + % This template uses several fonts not included with Windows/Linux by + % default. If you get compilation errors saying a font is missing, find the line + % on which the font is used and either change it to a font included with your + % operating system or comment the line out to use the default font. + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % TODO: + % 1. Integrate biber/bibtex for article citation under publications. + % 2. Figure out a smoother way for the document to flow onto the next page. + % 3. Add styling information for a "Projects/Hacks" section. + % 4. Add location/address information + % 5. Merge OpenFont and MacFonts as a single sty with options. + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % CHANGELOG: + % v1.1: + % 1. Fixed several compilation bugs with \\renewcommand + % 2. Got Open-source fonts (Windows/Linux support) + % 3. Added Last Updated + % 4. Move Title styling into .sty + % 5. Commented .sty file. + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % Known Issues: + % 1. Overflows onto second page if any column's contents are more than the + % vertical limit + % 2. Hacky space on the first bullet point on the second column. + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + ` +} + +function generateAwardsSection(awards) { + if (!awards) { + return '' + } + + return source` + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + % + % Awards + % + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \\section{Awards} + ${awards.map(award => { + const { name, details, date, location } = award + const info = [date, location].filter(Boolean).join(' | ') + + return stripIndent` + \\runsubsection{\\large{${name || ''}}} \\descript{${info}} \\\\ + ${details ? `${details}\\\\` : ''} + \\sectionsep + ` + })} + ` +} + +module.exports = template4 diff --git a/app/server/src/generator/templates/template6/index.js b/app/server/src/generator/templates/template6/index.js index 30581db4..a9b385f1 100644 --- a/app/server/src/generator/templates/template6/index.js +++ b/app/server/src/generator/templates/template6/index.js @@ -34,12 +34,9 @@ function generateProfileSection(profile) { if (names.length === 1) { nameStart = names[0] nameEnd = '' - } else if (names.length === 2) { - nameStart = names[0] - nameEnd = names[1] } else { - nameStart = names.slice(0, names.length - 1).join(' ') - nameEnd = names[names.length - 1] + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') } } diff --git a/app/server/src/generator/templates/template6/index.js~ b/app/server/src/generator/templates/template6/index.js~ new file mode 100644 index 00000000..40d943fa --- /dev/null +++ b/app/server/src/generator/templates/template6/index.js~ @@ -0,0 +1,214 @@ +const { stripIndent, source } = require('common-tags') +const { WHITESPACE } = require('../constants') + +function template6({ profile, schools, jobs, projects, skills, awards }) { + return stripIndent` + %!TEX TS-program = xelatex + \\documentclass[]{friggeri-cv} + + \\begin{document} + ${generateProfileSection(profile)} + ${generateEducationSection(schools)} + ${generateExperienceSection(jobs)} + ${generateSkillsSection(skills)} + ${generateProjectsSection(projects)} + ${generateAwardsSection(awards)} + ${WHITESPACE} + \\end{document} + ` +} + +function generateProfileSection(profile) { + if (!profile) { + return '\\header{}{}{}' + } + + const { fullName, email, phoneNumber, address, link } = profile + + let nameStart = '' + let nameEnd = '' + + if (fullName) { + const names = fullName.split(' ') + + if (names.length === 1) { + nameStart = names[0] + nameEnd = '' + }else { + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') + } + } + + if (nameStart && nameEnd) { + nameStart += ' ' + } + + const info = [email, phoneNumber, address, link].filter(Boolean).join(' | ') + + return stripIndent` + \\header{${nameStart}}{${nameEnd}}{${info}} + ` +} + +function generateEducationSection(schools) { + if (!schools) { + return '' + } + + return source` + \\section{education} + \\begin{entrylist} + ${schools.map(school => { + const { name, location, degree, major, gpa, graduationDate } = school + + let schoolLine = '' + + if (name) { + schoolLine += name + } + + if (degree && major) { + schoolLine += `, {\\normalfont ${degree} in ${major}}` + } else if (degree || major) { + schoolLine += `, {\\normalfont ${degree || major}}` + } + + return ` + \\entry + {${graduationDate || ''}} + {${schoolLine}} + {${location || ''}} + {${gpa ? `\\emph{GPA: ${gpa}}` : ''}} + ` + })} + \\end{entrylist} + ` +} + +function generateExperienceSection(jobs) { + if (!jobs) { + return '' + } + + return source` + \\section{experience} + \\begin{entrylist} + ${jobs.map(job => { + const { name, title, location, startDate, endDate, duties } = job + + let jobLine = '' + let dateRange = '' + let dutyLines + + if (name) { + jobLine += name + } + + if (title) { + jobLine += `, ${title}` + } + + if (duties) { + dutyLines = source` + \\vspace{-3mm}\\begin{itemize}[leftmargin=10pt,itemsep=4pt] + ${duties.map(duty => `\\item ${duty}`)} + \\end{itemize} + ` + } + + if (startDate && endDate) { + dateRange = `${startDate} – ${endDate}` + } else if (startDate) { + dateRange = `${startDate} – Present` + } else { + dateRange = endDate + } + + return ` + \\entry + {${dateRange}} + {${jobLine}} + {${location || ''}} + {${dutyLines}} + ` + })} + \\end{entrylist} + ` +} + +function generateSkillsSection(skills) { + if (!skills) { + return '' + } + + return source` + \\section{Skills} + \\begin{entrylist} + ${skills.map(({ name, details }) => { + const nameLine = name ? `${name}: ` : '' + const detailsLine = details ? `{\\normalfont ${details}}` : '' + + return `\\skill{}{${nameLine}${detailsLine}}` + })} + \\end{entrylist} + ` +} + +function generateProjectsSection(projects) { + if (!projects) { + return '' + } + + return source` + \\section{Projects} + \\begin{entrylist} + ${projects.map(project => { + const { name, description, technologies, link } = project + + let nameLine = '' + + if (name) { + nameLine += name + } + + if (technologies) { + nameLine += ` {\\normalfont ${technologies}}` + } + + return ` + \\entry + {} + {${nameLine}} + {${link || ''}} + {${description || ''}} + ` + })} + \\end{entrylist} + ` +} + +function generateAwardsSection(awards) { + if (!awards) { + return '' + } + + return source` + \\section{awards} + \\begin{entrylist} + ${awards.map(award => { + const { name, details, date, location } = award + + return stripIndent` + \\entry + {${date || ''}} + {${name || ''}} + {${location || ''}} + {${details || ''}} + ` + })} + \\end{entrylist} + ` +} + +module.exports = template6 From c508a8d6c082475079ef476eebbddd62cd0a835f Mon Sep 17 00:00:00 2001 From: Aviral Verma Date: Mon, 5 Jun 2017 15:11:55 +0530 Subject: [PATCH 2/7] fixed indentation --- app/server/src/generator/templates/template2/index.js | 5 +++-- app/server/src/generator/templates/template2/index.js~ | 5 +++-- app/server/src/generator/templates/template6/index.js | 4 ++-- app/server/src/generator/templates/template6/index.js~ | 7 ++++--- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/app/server/src/generator/templates/template2/index.js b/app/server/src/generator/templates/template2/index.js index df0b788d..068a7dd6 100644 --- a/app/server/src/generator/templates/template2/index.js +++ b/app/server/src/generator/templates/template2/index.js @@ -32,8 +32,9 @@ function generateProfileSection(profile) { if (names.length === 1) { nameStart = names[0] - } else { - nameStart = names[0] + nameEnd = '' + } else { + nameStart = names[0] nameEnd = names.slice(1,names.length).join(' ') } diff --git a/app/server/src/generator/templates/template2/index.js~ b/app/server/src/generator/templates/template2/index.js~ index df0b788d..068a7dd6 100644 --- a/app/server/src/generator/templates/template2/index.js~ +++ b/app/server/src/generator/templates/template2/index.js~ @@ -32,8 +32,9 @@ function generateProfileSection(profile) { if (names.length === 1) { nameStart = names[0] - } else { - nameStart = names[0] + nameEnd = '' + } else { + nameStart = names[0] nameEnd = names.slice(1,names.length).join(' ') } diff --git a/app/server/src/generator/templates/template6/index.js b/app/server/src/generator/templates/template6/index.js index a9b385f1..8f35153b 100644 --- a/app/server/src/generator/templates/template6/index.js +++ b/app/server/src/generator/templates/template6/index.js @@ -35,8 +35,8 @@ function generateProfileSection(profile) { nameStart = names[0] nameEnd = '' } else { - nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') } } diff --git a/app/server/src/generator/templates/template6/index.js~ b/app/server/src/generator/templates/template6/index.js~ index 40d943fa..ef3f662b 100644 --- a/app/server/src/generator/templates/template6/index.js~ +++ b/app/server/src/generator/templates/template6/index.js~ @@ -34,10 +34,11 @@ function generateProfileSection(profile) { if (names.length === 1) { nameStart = names[0] nameEnd = '' - }else { - nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') + } else { + nameStart = names[0] + nameEnd = names.slice(1,names.length).join(' ') } + } if (nameStart && nameEnd) { From 944e4e7c1d7e42028d8595716c1ef52cc0c84336 Mon Sep 17 00:00:00 2001 From: Aviral Verma Date: Mon, 5 Jun 2017 15:24:14 +0530 Subject: [PATCH 3/7] Delete index.js~ --- .../generator/templates/template2/index.js~ | 269 ------------------ 1 file changed, 269 deletions(-) delete mode 100644 app/server/src/generator/templates/template2/index.js~ diff --git a/app/server/src/generator/templates/template2/index.js~ b/app/server/src/generator/templates/template2/index.js~ deleted file mode 100644 index 068a7dd6..00000000 --- a/app/server/src/generator/templates/template2/index.js~ +++ /dev/null @@ -1,269 +0,0 @@ -const { stripIndent, source } = require('common-tags') -const { WHITESPACE } = require('../constants') - -function template2({ profile, schools, jobs, projects, skills, awards }) { - return stripIndent` - ${generateHeader()} - \\begin{document} - ${generateProfileSection(profile)} - ${generateEducationSection(schools)} - ${generateExperienceSection(jobs)} - ${generateSkillsSection(skills)} - ${generateProjectsSection(projects)} - ${generateAwardsSection(awards)} - ${WHITESPACE} - \\end{document} - ` -} - -function generateProfileSection(profile) { - if (!profile) { - return '' - } - - const { fullName, email, phoneNumber, address, link } = profile - - let nameLine = '' - - if (fullName) { - const names = fullName.split(' ') - let nameStart = '' - let nameEnd = '' - - if (names.length === 1) { - nameStart = names[0] - nameEnd = '' - } else { - nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') - } - - nameLine = `\\headerfirstnamestyle{${nameStart}} \\headerlastnamestyle{${nameEnd}} \\\\` - } - - const emailLine = email ? `{\\faEnvelope\\ ${email}}` : '' - const phoneLine = phoneNumber ? `{\\faMobile\\ ${phoneNumber}}` : '' - const addressLine = address ? `{\\faMapMarker\\ ${address}}` : '' - const linkLine = link ? `{\\faLink\\ ${link}}` : '' - const info = [emailLine, phoneLine, addressLine, linkLine] - .filter(Boolean) - .join(' | ') - - return stripIndent` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % Profile - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\begin{center} - ${nameLine} - \\vspace{2mm} - ${info} - \\end{center} - ` -} - -function generateEducationSection(schools) { - if (!schools) { - return '' - } - - return source` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % Education - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\cvsection{Education} - \\begin{cventries} - ${schools.map(school => { - const { name, location, degree, major, gpa, graduationDate } = school - - let degreeLine = '' - - if (degree && major) { - degreeLine = `${degree} in ${major}` - } else if (degree || major) { - degreeLine = degree || major - } - - return stripIndent` - \\cventry - {${degreeLine}} - {${name || ''}} - {${location || ''}} - {${graduationDate || ''}} - {${gpa ? `GPA: ${gpa}` : ''}} - ` - })} - \\end{cventries} - - \\vspace{-2mm} - ` -} - -function generateExperienceSection(jobs) { - if (!jobs) { - return '' - } - - return source` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % Experience - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\cvsection{Experience} - \\begin{cventries} - ${jobs.map(job => { - const { name, title, location, startDate, endDate, duties } = job - - let dateRange = '' - let dutyLines = '' - - if (startDate && endDate) { - dateRange = `${startDate} – ${endDate}` - } else if (startDate) { - dateRange = `${startDate} – Present` - } else { - dateRange = endDate - } - - if (duties) { - dutyLines = source` - \\begin{cvitems} - ${duties.map(duty => `\\item {${duty}}`)} - \\end{cvitems} - ` - } - - return stripIndent` - \\cventry - {${title || ''}} - {${name || ''}} - {${location || ''}} - {${dateRange}} - {${dutyLines}} - ` - })} - \\end{cventries} - ` -} - -function generateSkillsSection(skills) { - if (!skills) { - return '' - } - - return source` - \\cvsection{Skills} - \\begin{cventries} - \\cventry - {} - {\\def\\arraystretch{1.15}{\\begin{tabular}{ l l } - ${skills.map(skill => { - const { name, details } = skill - const nameLine = name ? `${name}: ` : '' - const detailsLine = `{\\skill{ ${details || ''}}}` - - return `${nameLine} & ${detailsLine} \\\\` - })} - \\end{tabular}}} - {} - {} - {} - \\end{cventries} - - \\vspace{-7mm} - ` -} - -function generateProjectsSection(projects) { - if (!projects) { - return '' - } - - return source` - \\cvsection{Projects} - \\begin{cventries} - ${projects.map(project => stripIndent` - \\cventry - {${project.description || ''}} - {${project.name || ''}} - {${project.technologies || ''}} - {${project.link || ''}} - {} - - \\vspace{-5mm} - - `)} - \\end{cventries} - ` -} - -function generateAwardsSection(awards) { - if (!awards) { - return '' - } - - return source` - \\cvsection{Honors \\& Awards} - \\begin{cvhonors} - ${awards.map(award => { - const { name, details, date, location } = award - - return stripIndent` - \\cvhonor - {${name || ''}} - {${details || ''}} - {${location || ''}} - {${date || ''}} - ` - })} - \\end{cvhonors} - ` -} - -function generateHeader() { - return stripIndent` - %!TEX TS-program = xelatex - %!TEX encoding = UTF-8 Unicode - % Awesome CV LaTeX Template - % - % This template has been downloaded from: - % https://github.com/posquit0/Awesome-CV - % - % Author: - % Claud D. Park - % http://www.posquit0.com - % - % Template license: - % CC BY-SA 4.0 (https://creativecommons.org/licenses/by-sa/4.0/) - % - - - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % Configuration - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - %%% Themes: Awesome-CV - \\documentclass[]{awesome-cv} - \\usepackage{textcomp} - %%% Override a directory location for fonts(default: 'fonts/') - \\fontdir[fonts/] - - %%% Configure a directory location for sections - \\newcommand*{\\sectiondir}{resume/} - - %%% Override color - % Awesome Colors: awesome-emerald, awesome-skyblue, awesome-red, awesome-pink, awesome-orange - % awesome-nephritis, awesome-concrete, awesome-darknight - %% Color for highlight - % Define your custom color if you don't like awesome colors - \\colorlet{awesome}{awesome-red} - %\\definecolor{awesome}{HTML}{CA63A8} - %% Colors for text - %\\definecolor{darktext}{HTML}{414141} - %\\definecolor{text}{HTML}{414141} - %\\definecolor{graytext}{HTML}{414141} - %\\definecolor{lighttext}{HTML}{414141} - - %%% Override a separator for social informations in header(default: ' | ') - %\\headersocialsep[\\quad\\textbar\\quad] - ` -} - -module.exports = template2 From 69375c243b5384864781d746c7bf82461506c33d Mon Sep 17 00:00:00 2001 From: Aviral Verma Date: Mon, 5 Jun 2017 15:25:44 +0530 Subject: [PATCH 4/7] Delete index.js~ --- .../generator/templates/template4/index.js~ | 335 ------------------ 1 file changed, 335 deletions(-) delete mode 100644 app/server/src/generator/templates/template4/index.js~ diff --git a/app/server/src/generator/templates/template4/index.js~ b/app/server/src/generator/templates/template4/index.js~ deleted file mode 100644 index 670fbe91..00000000 --- a/app/server/src/generator/templates/template4/index.js~ +++ /dev/null @@ -1,335 +0,0 @@ -const { stripIndent, source } = require('common-tags') -const { WHITESPACE } = require('../constants') - -function template4({ profile, schools, jobs, projects, skills, awards }) { - return stripIndent` - ${generateCommentHeader()} - \\documentclass[]{deedy-resume-openfont} - - \\begin{document} - ${generateProfileSection(profile)} - ${generateEducationSection(schools)} - ${generateExperienceSection(jobs)} - ${generateSkillsSection(skills)} - ${generateProjectsSection(projects)} - ${generateAwardsSection(awards)} - ${WHITESPACE} - \\end{document} - ` -} - -function generateProfileSection(profile) { - if (!profile) { - return '\\namesection{Your}{Name}{}' - } - - const { fullName, email, phoneNumber, address, link } = profile - - let nameStart = '' - let nameEnd = '' - - if (fullName) { - const names = fullName.split(' ') - - if (names.length === 1) { - nameStart = names[0] - nameEnd = '' - } else { - nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') - } - } - - const info = [email, phoneNumber, address, link].filter(Boolean).join(' | ') - - const sectionHeader = stripIndent` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % Profile - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - ` - - if (!fullName) { - return stripIndent` - ${sectionHeader} - \\centering{ - \\color{headings} - \\fontspec[Path = fonts/raleway/]{Raleway-Medium} - \\fontsize{11pt}{14pt} - \\selectfont ${info} - } - ` - } - - return stripIndent` - ${sectionHeader} - \\namesection{${nameStart}}{${nameEnd}}{${info}} - ` -} - -function generateEducationSection(schools) { - if (!schools) { - return '' - } - - return source` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % Education - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\section{Education} - \\raggedright - ${schools.map(school => { - const { name, location, degree, major, gpa, graduationDate } = school - - let line1 = '' - let line2 = '' - - if (name) { - line1 += `\\runsubsection{${name}}` - } - - if (degree && major) { - line1 += `\\descript{| ${degree} ${major}}` - } else if (degree) { - line1 += `\\descript{| ${degree}}` - } else if (major) { - line1 += `\\descript{| ${major}}` - } - - const locationAndDate = [location, graduationDate] - .filter(Boolean) - .join(' | ') - - if (locationAndDate) { - line1 += `\\hfill \\location{${locationAndDate}}` - } - - if (line1) { - line1 += '\\\\' - } - - if (gpa) { - line2 += `GPA: ${gpa}\\\\` - } - - return ` - ${line1} - ${line2} - \\sectionsep - ` - })} - ` -} - -function generateExperienceSection(jobs) { - if (!jobs) { - return '' - } - - return source` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % Experience - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\section{Experience} - ${jobs.map(job => { - const { name, title, location, startDate, endDate, duties } = job - - let line1 = '' - let dateRange = '' - let dutyLines = '' - - if (name) { - line1 += `\\runsubsection{${name}}` - } - - if (title) { - line1 += `\\descript{| ${title}}` - } - - if (startDate && endDate) { - dateRange = `${startDate} – ${endDate}` - } else if (startDate) { - dateRange = `${startDate} – Present` - } else { - dateRange = endDate - } - - if (location && dateRange) { - line1 += `\\hfill \\location{${location} | ${dateRange}}` - } else if (location) { - line1 += `\\hfill \\location{${location}}` - } else if (dateRange) { - line1 += `\\hfill \\location{${dateRange}}` - } - - if (duties) { - dutyLines = source` - \\begin{tightemize} - ${duties.map(duty => `\\item ${duty}`)} - \\end{tightemize} - ` - } - - return stripIndent` - ${line1} - ${dutyLines} - \\sectionsep - ` - })} - ` -} - -function generateSkillsSection(skills) { - if (!skills) { - return '' - } - - return source` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % Skills - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\section{Skills} - \\raggedright - \\begin{tabular}{ l l } - ${skills.map(skill => `\\descript{${skill.name}} & {\\location{${skill.details}}} \\\\`)} - \\end{tabular} - \\sectionsep - ` -} - -function generateProjectsSection(projects) { - if (!projects) { - return '' - } - - return source` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % Projects - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\section{Projects} - \\raggedright - ${projects.map(project => { - const { name, description, technologies, link } = project - - let line1 = '' - let line2 = '' - let line3 = '' - - if (name) { - line1 += `\\runsubsection{\\large{${name}}}` - } - - if (technologies) { - line2 += `\\descript{| ${technologies}}` - } - - if (link) { - line2 += `\\hfill \\location{${link}}` - } - - if (line2) { - line2 += '\\\\' - } - - if (description) { - line3 += `${description}\\\\` - } - - return ` - ${line1} - ${line2} - ${line3} - \\sectionsep - ` - })} - ` -} - -function generateCommentHeader() { - return stripIndent` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % This is a modified ONE COLUMN version of - % the following template: - % - % Deedy - One Page Two Column Resume - % LaTeX Template - % Version 1.1 (30/4/2014) - % - % Original author: - % Debarghya Das (http://debarghyadas.com) - % - % Original repository: - % https://github.com/deedydas/Deedy-Resume - % - % IMPORTANT: THIS TEMPLATE NEEDS TO BE COMPILED WITH XeLaTeX - % - % This template uses several fonts not included with Windows/Linux by - % default. If you get compilation errors saying a font is missing, find the line - % on which the font is used and either change it to a font included with your - % operating system or comment the line out to use the default font. - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % TODO: - % 1. Integrate biber/bibtex for article citation under publications. - % 2. Figure out a smoother way for the document to flow onto the next page. - % 3. Add styling information for a "Projects/Hacks" section. - % 4. Add location/address information - % 5. Merge OpenFont and MacFonts as a single sty with options. - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % CHANGELOG: - % v1.1: - % 1. Fixed several compilation bugs with \\renewcommand - % 2. Got Open-source fonts (Windows/Linux support) - % 3. Added Last Updated - % 4. Move Title styling into .sty - % 5. Commented .sty file. - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % Known Issues: - % 1. Overflows onto second page if any column's contents are more than the - % vertical limit - % 2. Hacky space on the first bullet point on the second column. - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - ` -} - -function generateAwardsSection(awards) { - if (!awards) { - return '' - } - - return source` - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - % - % Awards - % - %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \\section{Awards} - ${awards.map(award => { - const { name, details, date, location } = award - const info = [date, location].filter(Boolean).join(' | ') - - return stripIndent` - \\runsubsection{\\large{${name || ''}}} \\descript{${info}} \\\\ - ${details ? `${details}\\\\` : ''} - \\sectionsep - ` - })} - ` -} - -module.exports = template4 From c1ea83bec030e1d5792bd8cb8d5b5c44ac62ecaf Mon Sep 17 00:00:00 2001 From: Aviral Verma Date: Mon, 5 Jun 2017 15:26:10 +0530 Subject: [PATCH 5/7] Delete index.js~ --- .../generator/templates/template6/index.js~ | 215 ------------------ 1 file changed, 215 deletions(-) delete mode 100644 app/server/src/generator/templates/template6/index.js~ diff --git a/app/server/src/generator/templates/template6/index.js~ b/app/server/src/generator/templates/template6/index.js~ deleted file mode 100644 index ef3f662b..00000000 --- a/app/server/src/generator/templates/template6/index.js~ +++ /dev/null @@ -1,215 +0,0 @@ -const { stripIndent, source } = require('common-tags') -const { WHITESPACE } = require('../constants') - -function template6({ profile, schools, jobs, projects, skills, awards }) { - return stripIndent` - %!TEX TS-program = xelatex - \\documentclass[]{friggeri-cv} - - \\begin{document} - ${generateProfileSection(profile)} - ${generateEducationSection(schools)} - ${generateExperienceSection(jobs)} - ${generateSkillsSection(skills)} - ${generateProjectsSection(projects)} - ${generateAwardsSection(awards)} - ${WHITESPACE} - \\end{document} - ` -} - -function generateProfileSection(profile) { - if (!profile) { - return '\\header{}{}{}' - } - - const { fullName, email, phoneNumber, address, link } = profile - - let nameStart = '' - let nameEnd = '' - - if (fullName) { - const names = fullName.split(' ') - - if (names.length === 1) { - nameStart = names[0] - nameEnd = '' - } else { - nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') - } - - } - - if (nameStart && nameEnd) { - nameStart += ' ' - } - - const info = [email, phoneNumber, address, link].filter(Boolean).join(' | ') - - return stripIndent` - \\header{${nameStart}}{${nameEnd}}{${info}} - ` -} - -function generateEducationSection(schools) { - if (!schools) { - return '' - } - - return source` - \\section{education} - \\begin{entrylist} - ${schools.map(school => { - const { name, location, degree, major, gpa, graduationDate } = school - - let schoolLine = '' - - if (name) { - schoolLine += name - } - - if (degree && major) { - schoolLine += `, {\\normalfont ${degree} in ${major}}` - } else if (degree || major) { - schoolLine += `, {\\normalfont ${degree || major}}` - } - - return ` - \\entry - {${graduationDate || ''}} - {${schoolLine}} - {${location || ''}} - {${gpa ? `\\emph{GPA: ${gpa}}` : ''}} - ` - })} - \\end{entrylist} - ` -} - -function generateExperienceSection(jobs) { - if (!jobs) { - return '' - } - - return source` - \\section{experience} - \\begin{entrylist} - ${jobs.map(job => { - const { name, title, location, startDate, endDate, duties } = job - - let jobLine = '' - let dateRange = '' - let dutyLines - - if (name) { - jobLine += name - } - - if (title) { - jobLine += `, ${title}` - } - - if (duties) { - dutyLines = source` - \\vspace{-3mm}\\begin{itemize}[leftmargin=10pt,itemsep=4pt] - ${duties.map(duty => `\\item ${duty}`)} - \\end{itemize} - ` - } - - if (startDate && endDate) { - dateRange = `${startDate} – ${endDate}` - } else if (startDate) { - dateRange = `${startDate} – Present` - } else { - dateRange = endDate - } - - return ` - \\entry - {${dateRange}} - {${jobLine}} - {${location || ''}} - {${dutyLines}} - ` - })} - \\end{entrylist} - ` -} - -function generateSkillsSection(skills) { - if (!skills) { - return '' - } - - return source` - \\section{Skills} - \\begin{entrylist} - ${skills.map(({ name, details }) => { - const nameLine = name ? `${name}: ` : '' - const detailsLine = details ? `{\\normalfont ${details}}` : '' - - return `\\skill{}{${nameLine}${detailsLine}}` - })} - \\end{entrylist} - ` -} - -function generateProjectsSection(projects) { - if (!projects) { - return '' - } - - return source` - \\section{Projects} - \\begin{entrylist} - ${projects.map(project => { - const { name, description, technologies, link } = project - - let nameLine = '' - - if (name) { - nameLine += name - } - - if (technologies) { - nameLine += ` {\\normalfont ${technologies}}` - } - - return ` - \\entry - {} - {${nameLine}} - {${link || ''}} - {${description || ''}} - ` - })} - \\end{entrylist} - ` -} - -function generateAwardsSection(awards) { - if (!awards) { - return '' - } - - return source` - \\section{awards} - \\begin{entrylist} - ${awards.map(award => { - const { name, details, date, location } = award - - return stripIndent` - \\entry - {${date || ''}} - {${name || ''}} - {${location || ''}} - {${details || ''}} - ` - })} - \\end{entrylist} - ` -} - -module.exports = template6 From fa99e0b60a565cb5b347989d5b1b02a79fb05b7a Mon Sep 17 00:00:00 2001 From: Aviral Verma Date: Mon, 5 Jun 2017 15:29:49 +0530 Subject: [PATCH 6/7] removed some weird stuff --- app/server/src/generator/templates/template2/index.js | 1 - 1 file changed, 1 deletion(-) diff --git a/app/server/src/generator/templates/template2/index.js b/app/server/src/generator/templates/template2/index.js index 068a7dd6..03da10e9 100644 --- a/app/server/src/generator/templates/template2/index.js +++ b/app/server/src/generator/templates/template2/index.js @@ -32,7 +32,6 @@ function generateProfileSection(profile) { if (names.length === 1) { nameStart = names[0] - nameEnd = '' } else { nameStart = names[0] nameEnd = names.slice(1,names.length).join(' ') From 9fe2e048c85df771c8477ca3f1a82fca317fc391 Mon Sep 17 00:00:00 2001 From: Aviral Verma Date: Mon, 5 Jun 2017 17:49:28 +0530 Subject: [PATCH 7/7] some more stupid things --- app/server/src/generator/templates/template2/index.js | 2 +- app/server/src/generator/templates/template4/index.js | 2 +- app/server/src/generator/templates/template6/index.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/server/src/generator/templates/template2/index.js b/app/server/src/generator/templates/template2/index.js index 068a7dd6..1276827f 100644 --- a/app/server/src/generator/templates/template2/index.js +++ b/app/server/src/generator/templates/template2/index.js @@ -35,7 +35,7 @@ function generateProfileSection(profile) { nameEnd = '' } else { nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') + nameEnd = names.slice(1, names.length).join(' ') } nameLine = `\\headerfirstnamestyle{${nameStart}} \\headerlastnamestyle{${nameEnd}} \\\\` diff --git a/app/server/src/generator/templates/template4/index.js b/app/server/src/generator/templates/template4/index.js index 670fbe91..dd984382 100644 --- a/app/server/src/generator/templates/template4/index.js +++ b/app/server/src/generator/templates/template4/index.js @@ -36,7 +36,7 @@ function generateProfileSection(profile) { nameEnd = '' } else { nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') + nameEnd = names.slice(1, names.length).join(' ') } } diff --git a/app/server/src/generator/templates/template6/index.js b/app/server/src/generator/templates/template6/index.js index 8f35153b..4a6e3eac 100644 --- a/app/server/src/generator/templates/template6/index.js +++ b/app/server/src/generator/templates/template6/index.js @@ -36,7 +36,7 @@ function generateProfileSection(profile) { nameEnd = '' } else { nameStart = names[0] - nameEnd = names.slice(1,names.length).join(' ') + nameEnd = names.slice(1, names.length).join(' ') } }