I'm using Ubuntu 16.04 and I installed Hugo using :
sudo apt-get install hugo
My hugo version :
Hugo Static Site Generator v0.16-DEV BuildDate: 2016-02-06T12:14:17-05:00
I was trying to deploy hugo-theme-bleak as per the Quick start tutorial in Hugo website.
After cloning the theme using
git clone https://github.com/Zenithar/hugo-theme-bleak.git
I tried running hugo server using following command :
hugo server --theme=hugo-theme-bleak --buildDrafts
But I'm getting the following error , and the page is not generated properly.
ERROR: 2017/07/15 12:40:28 server.go:121: port 1313 already in use,
attempting to use an available port
ERROR: 2017/07/15 12:40:28 template.go:350: template: theme/partials
/header.html:112: function "jsonify" not defined
ERROR: 2017/07/15 12:40:28 template.go:350: template: theme/partials
/pagination.html:4: function "slice" not defined
ERROR: 2017/07/15 12:40:28 template.go:119: html/template:
"theme/partials/header.html" is an incomplete template in theme/partials
/header.html
ERROR: 2017/07/15 12:40:28 template.go:119: html/template:
"theme/partials/pagination.html" is an incomplete template in
theme/partials/pagination.html
ERROR: 2017/07/15 12:40:28 template.go:119: html/template:
"theme/partials/header.html" is an incomplete template in theme/partials
/header.html
ERROR: 2017/07/15 12:40:28 template.go:119: html/template:
"theme/partials/header.html" is an incomplete template in theme/partials
/header.html
ERROR: 2017/07/15 12:40:28 template.go:119: html/template:
"theme/partials/pagination.html" is an incomplete template in
theme/partials/pagination.html
1 of 1 draft rendered
0 future content
1 pages created
0 non-page files copied
2 paginator pages created
0 categories created
0 tags created
in 15 ms
The same sort of 'function not defined' error popping up with several other themes also, which I tried.
Any ideas on how to fix ?
Thanks for help!
I got the answer.!
The error is because the installed version of Hugo is too old.
apt repositories have very old version of hugo in it.
It is advised to download '.deb' packages for ubuntu systems from the git releases page of hugo directly.
Related
BUILD FAILED in 2s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
FAILURE: Build failed with an exception.
What went wrong:
A problem occurred configuring root project 'Peace Garden'.
Could not determine the dependencies of null.
Could not resolve all task dependencies for configuration ':classpath'.
> Could not resolve com.facebook.react:react-native:+.
Required by:
project :
> No matching variant of com.facebook.react:react-native:0.71.0-rc.0 was found. The consumer was configured
to find a runtime of a library compatible with Java 11, packaged as a jar, and its dependencies declared externally,
as well as attribute 'org.gradle.plugin.api-version' with value '7.3.3'
I'm following the instructions on the official polymer page:
https://www.polymer-project.org/1.0/start/toolbox/set-up
but when I execute this command:
polymer init starter-kit
I receive this error:
error: [init] Template polymer-init-starter-kit:app not found
error: [cli.main] cli runtime exception: Error: Template polymer-init-starter-kit:app not found
error: [cli.main] Error: Template polymer-init-starter-kit:app not found
at Object. (C:\Users\ruben\AppData\Roaming\npm\node_modules\polymer-cli\lib\init\init.js:223:19)
at Generator.next ()
at fulfilled (C:\Users\ruben\AppData\Roaming\npm\node_modules\polymer-cli\lib\init\init.js:17:58)
at
at process._tickCallback (internal/process/next_tick.js:188:7)
at Function.Module.runMain (module.js:695:11)
at startup (bootstrap_node.js:191:16)
at bootstrap_node.js:612:3
my version polymer-cli: 1.7.2
my version node is: 8.11.2
my version npm is:5.6.0
my version bower is: 1.8.4
What am I doing wrong?
Thanks very much.
run this commands:
git clone https://github.com/Polymer/polymer-starter-kit.git
cd polymer-starter-kit
git checkout v2.2.0
bower install
regards
Today I received a new development and a new production server. I have installed my XAMPP on my dev server in the C:\\Users\\Public directory. I have installed the Apache server and changed it so that it will be executed as a different, less privileged user. After that, I cloned my webapp project that connects to AD and a MS SQL server.
Bear in mind that all of this is already working on my previous development server.
Now, I copied the php.ini file from my php directory into the php directory of the new server.
When executing the server, I get these errors in my apache error log:
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_sqlsrv_56_ts.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_pdo_sqlsrv_56_ts.dll' - The specified module could not be found.\r\n in Unknown on line 0
When trying to use sqlsrv_connect, which also works perfectly on the old dev server, I get the error:
Fatal error: Uncaught Error: Call to undefined function sqlsrv_connect() in C:\Users\Public\xampp\htdocs\sql_functions.php:18
After typing this, I attempted to copy the entire ext directory over. This was a bad mistake:
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_bz2.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_curl.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_fileinfo.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_gd2.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_gettext.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_ldap.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_mbstring.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_exif.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_mysql.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_mysqli.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_pdo_sqlite.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_sqlsrv_56_ts.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_pdo_sqlsrv_56_ts.dll' - The specified module could not be found.\r\n in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library 'C:\\Users\\Public\\xampp\\php\\ext\\php_openssl.dll' - The specified module could not be found.\r\n in Unknown on line 0
I'm pretty sure that I'm using a different Apache version.
New server: 2.4.26
Old server: Apache/2.4.23 (Win32) OpenSSL/1.0.2h PHP/5.6.28
Edit: I just compared the two httpd.conf files. Except for the paths and about 7 lines about a <IfModule headers_module>, there is no difference.
I did it!
I downloaded the most recent release from here.
Then I simply edited php.ini to point to the newest file, which was, in this case:
extension=php_sqlsrv_71_ts.dll
extension=php_pdo_sqlsrv_71_ts.dll
Try to x64 or x86 versions. I solved this method.
I wanted to dive into CN1 soures. I've followed this and this tutorial with git. However in NetBeans when I ctrl-click on a CN1 object it shows "Showing generated source file. No sources are attached to class' JAR file.". If I attach the sources I've just downloaded ie "CodenameOne/CodenameOne/src" the sources are still unfound!
I tried to clean and build the project but errors appeared :
Building jar: /home/pathTo/CodenameOneSRC/CodenameOne/CodenameOne/dist/CodenameOne.jar
CodenameOne.jar:
JavaSE.init:
JavaSE.deps-jar:
Created dir: /home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/build
Updating property file: /home/pathTo/myProject/build/built-jar.properties
Created dir: /home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/build/classes
Created dir: /home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/build/empty
Created dir: /home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/build/generated-sources/ap-source-output
Compiling 21 source files to /home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/build/classes
warning: [options] bootstrap class path not set in conjunction with -source 1.7
/home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/src/com/codename1/impl/javase/JavaSEPort.java:115: error: package com.jhlabs.image does not exist
import com.jhlabs.image.GaussianFilter;
/home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/src/com/codename1/impl/javase/JavaSEPort.java:8757: error: cannot find symbol
GaussianFilter gf = new GaussianFilter(radius);
symbol: class GaussianFilter
location: class JavaSEPort
/home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/src/com/codename1/impl/javase/JavaSEPort.java:8757: error: cannot find symbol
GaussianFilter gf = new GaussianFilter(radius);
symbol: class GaussianFilter location: class JavaSEPort
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
3 errors
1 warning
/home/pathTo/myProject/nbproject/build-impl.xml:914: The following error occurred while executing this line:
/home/pathTo/myProject/nbproject/build-impl.xml:1445: The following error occurred while executing this line:
/home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/nbproject/build-impl.xml:937: The following error occurred while executing this line:
/home/pathTo/CodenameOneSRC/CodenameOne/Ports/JavaSE/nbproject/build-impl.xml:269: Compile failed; see the compiler error output for details.
BUILD FAILED (total time: 14 seconds)
Furthermore the project cannot be run anymore because the main class is not found (although I added the ports/JavaSE.jar in the run section).
What can I do to correctly attach sources and make change to CN1 source code ?
Any help appreciated,
Regards
You need the cn1-binaries project and need to make sure the paths within the JavaSE project lead to valid locations within that project.
E.g. GaussianFilter is defined within Filters.jar that resides in that project.
Getting this error only on travis, working fine on my local machine.
Using Karma with Webpack and gulp for angular test cases.
Module not found: Error: Cannot resolve 'file' or 'directory' ../HTTPmocks/userService.mock.js in /home/travis/build/node-app/client-test-dest/factories
# ./client-test-dest/factories/UserFactory.spec.js 3:23-66
Already tried using 'path' as path.join and path.resolve. But webpack fails on local with error,
WARNING in ./client-test-dest/factories/UserFactory.spec.js
Critical dependencies:
9:9-84 the request of a dependency is an expression
10:9-89 the request of a dependency is an expression
# ./client-test-dest/factories/UserFactory.spec.js 9:9-84 10:9-89
WARNING in ./client-test-dest/factories ^\.\/.*$
Module not found: Error: a dependency to an entry point is not allowed
# ./client-test-dest/factories ^\.\/.*$
Node: 4.4.7
Solved!
Issue was that git was ignoring case changes for file rename.
I did a rename in previous commits and was requiring files accordingly.
Other thing: I'm using mac OS which is case-insensitive, so at some point webpack wasn't showing me any error, but travis is running with Linux. So it was causing error there.
MUST! Every developer should run: git config core.ignorecase false
on local. Well, I think this should be default behaviour of git to check for case-sensitive changes.