Advertisement
Guest User

Untitled

a guest
Feb 21st, 2018
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.53 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. occ_command() {
  4. check_command sudo -u www-data php "$NCPATH"/occ "$@";
  5. }
  6.  
  7. occ_command fulltextsearch:configure "{"search_platform":"OCA\\FullTextSearch_ElasticSearch\\Platform\\ElasticSearchPlatform"}"
  8. occ_command fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http:\\\\${NCADMIN}:${ROREST}@localhost:9200\"\,\"elastic_index\":\"${NCADMIN}\"}"
  9. occ_command files_fulltextsearch:configure "{\"files_pdf\":\"1\"\,\"files_office\":\"1\"}"
  10. occ_command fulltextsearch:index
  11.  
  12. gives me
  13.  
  14. $ shellcheck myscript
  15.  
  16. Line 7:
  17. occ_command fulltextsearch:configure "{"search_platform":"OCA\\FullTextSearch_ElasticSearch\\Platform\\ElasticSearchPlatform"}"
  18. ^-- SC2140: Word is of the form "A"B"C" (B indicated). Did you mean "ABC" or "A\"B\"C"?
  19. ^-- SC2140: Word is of the form "A"B"C" (B indicated). Did you mean "ABC" or "A\"B\"C"?
  20.  
  21. Line 8:
  22. occ_command fulltextsearch_elasticsearch:configure "{\"elastic_host\":\"http:\\\\${NCADMIN}:${ROREST}@localhost:9200\"\,\"elastic_index\":\"${NCADMIN}\"}"
  23. >> ^-- SC1117: Backslash is literal in "\,". Prefer explicit escaping: "\\,".
  24.  
  25. Line 9:
  26. occ_command files_fulltextsearch:configure "{\"files_pdf\":\"1\"\,\"files_office\":\"1\"}"
  27. >> ^-- SC1117: Backslash is literal in "\,". Prefer explicit escaping: "\\,".
  28.  
  29. $
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement