Atom安裝插件的幾種方式

Atom安裝插件的幾種方式

GUI安裝

  1. 打開Atom->File->Settings->Install
  2. 輸入你想要安裝的插件名/Theme名

命令行安裝

  1. 打開cmd命令行程序
  2. 切換到.atom/package目錄(通常在用戶目錄下)
  3. 輸入命令apm install package_name,其中package_name是插件的名字

手動安裝

手動安裝

  1. 在atom.io網站找到你想要的插件
  2. 進入插件的github頁面
  3. 克隆倉庫到本地
  4. 將下載的文件拷貝到.atom/package目錄
  5. 在cmd進入插件目錄,輸入apm install安裝
var >>~~hello~~<< = 'hello world' var >>==hello==<< = 'hello world' var >>**hello**<< = 'hello world' var >>++hello++<< = 'hello world'
  1. import org.apache.commons.codec.digest.DigestUtils; 
  2. import org.apache.commons.io.IOUtils; 
  3.  
  4. import java.io.*; 
  5. import java.math.BigInteger; 
  6. import java.security.MessageDigest; 
  7.  
  8. public class Md5Util { 
  9.  
  10. private static MessageDigest md5; 
  11.  
  12. static { 
  13. try { 
  14. md5 = MessageDigest.getInstance("MD5"); 
  15. } catch (Exception e) { 
  16. throw new RuntimeException(e); 
  17. } 
  18. } 
  19.  
  20. public static String getMd5(String string) { 
  21. try { 
  22. byte[] bs = md5.digest(string.getBytes("UTF-8")); 
  23. StringBuilder sb = new StringBuilder(40); 
  24. for (byte x : bs) { 
  25. if ((x & 0xff) >> 4 == 0) { 
  26. sb.append("0").append(Integer.toHexString(x & 0xff)); 
  27. } else { 
  28. sb.append(Integer.toHexString(x & 0xff)); 
  29. } 
  30. } 
  31. return sb.toString(); 
  32. } catch (UnsupportedEncodingException e) { 
  33. throw new RuntimeException(e); 
  34. } 
  35. }
相關文章
相關標籤/搜索