Downloaded an open source project ,maven Organized in form , One of the dependency packages is IKAnalyzer.

because mvnrepository Does not exist in the IKAnalyzer Coordinates of , Therefore, the dependent package needs to be downloaded and installed locally maven Only in the warehouse .

IKAnalyzer Project GitHub The address is https://github.com/wks/ik-analyzer

Download and enter ik-analyzer-master Catalog (POM File directory ),

function mvn command :

mvn install -Dmaven.test.skip=true

And then there was a whole bunch of mistakes , Almost every line of error has “ code GBK Unmapped characters of ” A few words , I don't know where the mistake is .

Then use the following command parameters

mvn install -e -X -Dmaven.test.skip=true >.\1.txt

Show the stack details of the error and export it to a file ( because cmd The command line displays a limited number of lines , If you cover the back, you can't see the front )

The figure below intercepts some error messages :

open \ik-analyzer-master\src\main\java\org\wltea\analyzer\dic.Hit.java Source file , It is found that the number of lines corresponding to the error prompt are all Chinese comments

Now the question is clear , Because the operating system is Windows7 Simplified Chinese version , therefore maven The default source file encoding is GBK, And the source file is by utf-8 Code saved , therefore maven The compiler follows GBK Unrecognized character set utf-8 Chinese characters of , So there was a mistake .

Once the problem is solved, it's easy , stay IKAnalyzer Project pom The encoding format is specified in the file , Add such an attribute :

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

Here's the picture :

And then do it again maven Installation command for , Decisive success

Remember a Maven compile IKAnalyzer More about failures and solutions

  1. LoadLibrary The solution to the failure of loading dynamic library

    from:http://blog.sina.com.cn/s/blog_62ad1b8101017qub.html if DLL Not in the same directory as the caller , It can be used LoadLibrary(L"DLL most ...

  2. linux There is insufficient space in the next compilation, and the solution is

    linux There is insufficient space in the next compilation, and the solution is There was a problem compiling the kernel : AS      .tmp_kallsyms1.o .tmp_kallsyms1.S:2: fatal error: when writing ...

  3. arcgis install msi Installation package tips &quot; When not marked as running , Called RunScript” terms of settlement

    install msi Installation package tips " When not marked as running , Called RunScript” terms of settlement   windows/temp Directory related permissions are not correct , Right click temp Folder , Select administrator to get all permissions .

  4. Data Base sqlServer sa The solution to user login failure

    sqlserver sa The solution to user login failure As shown in the figure below, imitate : 1. Right click - attribute 2. Find security : 3. Check as shown in the figure : 4.sa User password reset : 5. Service to restart :

  5. WeChat public platform Token Solutions to validation failure

    WeChat public platform Token Solutions to validation failure 1. You can see url and token Whether it is right 2. Check whether the server port is 80 port 3. You can record log Log to judge whether to receive the information submitted by wechat 1.$fp=fopen ...

  6. Sql Server 2008 Solutions to failed uninstall and reinstallation !( Try again and again , All the methods are effective !)

    Sql Server 2008 Solutions to failed uninstall and reinstallation !( Try again and again , All the methods are effective !) 1. Unload all tapes in the control panel sql server The program . 2. stay C disc C:\Program Files in sqlserv ...

  7. npm install error install chromedriver A failed solution

    npm install chromedriver A failed solution npm install chromedriver when , Occasionally there are mistakes , The error prompt is similar to :npm ERR! chromedriver@2.35.0 install: ...

  8. WCF The solution to failure caused by excessive data transmission

    WCF The solution to failure caused by excessive data transmission   WCF By default, the service does not configure the limited size of data transmission , So the default size seems to be 65535B, Only then 65KB about , If you want to transmit larger data , You need to specify the size of the buffer manually ...

  9. Genymotion Solutions to slow or failed downloading of virtual images

    Genymotion Solutions to slow or failed downloading of virtual images http://files2.genymotion.com/dists/8.0.0/ova/genymotion_vbox86p_8.0_18061 ...

Random recommendation

  1. hibernate( 7、 ... and ) hibernate In the inquiry way detailed explanation

    preface Previous pair hibernate Queries in are always confused , I don't know what's in it . Because of the lack of summary . Before reading this article , What you should know is some query operations in the database , Multi table query, etc , If you don't understand , You can go and have a look first MySQL Count ...

  2. spring web MVC

    details :http://blog.csdn.net/mic_hero/article/details/50237627

  3. AES encryption 16 Conversion between decimal and binary

    import java.security.Key; import javax.crypto.Cipher; import javax.crypto.KeyGenerator; import javax ...

  4. WordPress 3.5.1 Remote code execution vulnerability

    Vulnerability version : WordPress 3.5.1 Vulnerability description : WordPress It's a use PHP Language development blog platform , Users can support PHP and MySQL Set up your own blog on the server of the database . Also can put the WordPre ...

  5. Start Swift The journey - HelloWorld

    //: Playground - noun: a place where people can play import UIKit var str = "Hello, playground& ...

  6. docker Deploy nginx

    # Download mirroring docker pull nginx # mount   file And the folder must exist docker run -p 80:80 --name mynginx -v $PWD/www:/www -v $P ...

  7. tornado+websocket+mongodb Achieve online video text chat

    I learned recently tornado and mongo, So combine websocket Realize a chat function , So as to deepen the impression of relevant knowledge points 1.websocket overview webscoket It's a full duplex protocol , Client connection service ...

  8. 20172330 2017-2018-1 《Java Programming 》 Week 6 learning summary

    Student number 2017-2018-2 < Programming and data structure > Week 6 learning summary Summary of the learning content of the textbook This chapter is mainly about array learning : Array is a simple and powerful programming language structure , For grouping and organizing data . stay java in , ...

  9. sklearn The training of visual model tests convergence and feature importance

    show the code: # Plot training deviance def plot_training_deviance(clf, n_estimators, X_test, y_test ...

  10. Spring Web Async Asynchronous processing #Callable #DeferredResult

    Spring MVC There are two ways to handle asynchronous requests scene : Tomcat For the main thread performance bottleneck , When Tomcat Too many concurrent requests , When the number of threads is full , There will be a request waiting Tomcat Handle , At this time, you can use sub threads to process business ...