Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Command \FA already defined #234

Closed
OJFord opened this issue Oct 2, 2018 · 7 comments
Closed

Error: Command \FA already defined #234

OJFord opened this issue Oct 2, 2018 · 7 comments

Comments

@OJFord
Copy link
Collaborator

OJFord commented Oct 2, 2018

https://github.com/posquit0/Awesome-CV/blob/master/awesome-cv.cls#L164 causes:

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!
! LaTeX error: "xparse/command-already-defined"
!
! Command '\FA' already defined!
!
! See the LaTeX3 documentation for further information.
!
! For immediate help type H <return>.
!...............................................

due to a change in fontspec as described in: https://tex.stackexchange.com/a/453198/73121.

OJFord added a commit to OJFord/Awesome-CV that referenced this issue Oct 2, 2018

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
This commit fixes an issue when using recent fontspec versions.

Described in: https://tex.stackexchange.com/a/453198/73121

Closes posquit0#234.
@jeongwhanchoi
Copy link

jeongwhanchoi commented Oct 9, 2018

You should specify the extension of the font(e.g. otf).
This is my pull request with adding the extension .otf.

@Thaodan
Copy link

Thaodan commented Oct 15, 2018

I used setfont instead of newfont and now it runs again. Adding the extensions to the font didn't help.

@haseebmahmud
Copy link

I used setfont instead of newfont and now it runs again. Adding the extensions to the font didn't help.

Could you tell me what you did exactly? In a bit detail?

@Thaodan
Copy link

Thaodan commented Nov 1, 2018

Change newfont to setfont in the line with the error

@redragonx
Copy link

Arch Linux users: You'll need https://aur.archlinux.org/packages/ttf-font-awesome-4/ (Version 4 in AUR) then edit awesome-cv.cls file at line 164: to have

\setfontfamily\FA[Path=\@fontdir]{FontAwesome}
% Set font for header (default is Roboto)
\setfontfamily\headerfont[
  Path=\@fontdir,
  UprightFont=*-Regular,
  ItalicFont=*-Italic,
  BoldFont=*-Bold,
  BoldItalicFont=*-BoldItalic,
]{Roboto}

\setfontfamily\headerfontlight[
  Path=\@fontdir,
  UprightFont=*-Thin,
  ItalicFont=*-ThinItalic,
  BoldFont=*-Medium,
  BoldItalicFont=*-MediumItalic,
]{Roboto}

@ashwinvis
Copy link

@redragonx I am on ArchLinux, but I didn't need FontAwesome 4

$ pacsearch ttf-font
...
community/ttf-font-awesome 5.5.0-1 [installed]
    Iconic font designed for Bootstrap

Just the patching the .cls file was sufficient

diff --git a/awesome-cv.cls b/awesome-cv.cls
index d1c1074..48c3da2 100644
--- a/awesome-cv.cls
+++ b/awesome-cv.cls
@@ -161,7 +161,7 @@
 %                Configuration for fonts
 %-------------------------------------------------------------------------------
 % Set the FontAwesome font to be up-to-date.
-\newfontfamily\FA[Path=\@fontdir]{FontAwesome}
+\setfontfamily\FA[Path=\@fontdir]{FontAwesome}
 % Set font for header (default is Roboto)
 \newfontfamily\headerfont[
   Path=\@fontdir,

ashwinvis added a commit to ashwinvis/Awesome-CV that referenced this issue Nov 25, 2018

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
@chang48
Copy link

chang48 commented Dec 2, 2018

Just the patching the .cls file was sufficient

diff --git a/awesome-cv.cls b/awesome-cv.cls
index d1c1074..48c3da2 100644
--- a/awesome-cv.cls
+++ b/awesome-cv.cls
@@ -161,7 +161,7 @@
 %                Configuration for fonts
 %-------------------------------------------------------------------------------
 % Set the FontAwesome font to be up-to-date.
-\newfontfamily\FA[Path=\@fontdir]{FontAwesome}
+\setfontfamily\FA[Path=\@fontdir]{FontAwesome}
 % Set font for header (default is Roboto)
 \newfontfamily\headerfont[
   Path=\@fontdir,

I have the same error. But thanks to @ashwinvis, the patch fixes the problem.

rekentuig added a commit to rekentuig/Awesome-CV-docker that referenced this issue May 14, 2019

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
This commit fixes an issue when using recent fontspec versions.

Described in: https://tex.stackexchange.com/a/453198/73121

Closes posquit0#234.
aminmkhan added a commit to aminmkhan/Awesome-CV that referenced this issue Aug 9, 2019
- Fixes error: `! LaTeX3 Error: Command '\FA' already defined!` (posquit0, issue posquit0#234)
- Fixes error: `font not found` (posquit0, PR posquit0#98)
aminmkhan added a commit to aminmkhan/Awesome-CV that referenced this issue Aug 9, 2019
- Fixes error: `! LaTeX3 Error: Command '\FA' already defined!` (posquit0, issue posquit0#234)
- Fixes error: `font not found` (posquit0, PR posquit0#98)
thatonesysadmin added a commit to thatonesysadmin/Awesome-CV that referenced this issue Feb 4, 2020
polarmutex referenced this issue in polarmutex/Awesome-CV Apr 16, 2020
gnikit added a commit to gnikit/Awesome-CV that referenced this issue Sep 21, 2020
jonghoonseo added a commit to jonghoonseo/Awesome-CV that referenced this issue Sep 25, 2020
osipxd added a commit to osipxd/Awesome-CV that referenced this issue Nov 18, 2020
Fix posquit0#234: redefinition of \FA, upgrade to fontawesome5
janmayer pushed a commit to janmayer/Awesome-CV that referenced this issue Mar 30, 2021
This commit fixes an issue when using recent fontspec versions.

Described in: https://tex.stackexchange.com/a/453198/73121

Closes posquit0#234.

Fix fontawesome icons not rendering
vahlkar added a commit to vahlkar/Awesome-CV that referenced this issue Jul 25, 2021
Griffin-Brome added a commit to Griffin-Brome/Resume that referenced this issue Aug 23, 2021
OJFord added a commit to OJFord/Awesome-CV that referenced this issue Nov 10, 2021
This commit fixes an issue when using recent fontspec versions.

Described in: https://tex.stackexchange.com/a/453198/73121

Closes posquit0#234.
@OJFord OJFord closed this as completed in af2d81a Nov 10, 2021
OJFord added a commit that referenced this issue Nov 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants