KXStudio Website https://kx.studio/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

133 lines
4.5KB

  1. <?php
  2. /*************************************************************************************
  3. * rpmspec.php
  4. * ---------------------------------
  5. * Author: Paul Grinberg (gri6507 TA unity-linux TOD org)
  6. * Copyright: (c) 2010 Paul Grinberg
  7. * Release Version: 1.0.8.11
  8. * Date Started: 2010/04/27
  9. *
  10. * RPM Spec language file for GeSHi.
  11. *
  12. * CHANGES
  13. * -------
  14. * 2010/04/27 (0.1)
  15. * - First Release
  16. *
  17. *************************************************************************************
  18. *
  19. * This file is part of GeSHi.
  20. *
  21. * GeSHi is free software; you can redistribute it and/or modify
  22. * it under the terms of the GNU General Public License as published by
  23. * the Free Software Foundation; either version 2 of the License, or
  24. * (at your option) any later version.
  25. *
  26. * GeSHi is distributed in the hope that it will be useful,
  27. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  28. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  29. * GNU General Public License for more details.
  30. *
  31. * You should have received a copy of the GNU General Public License
  32. * along with GeSHi; if not, write to the Free Software
  33. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  34. *
  35. ************************************************************************************/
  36. $language_data = array (
  37. 'LANG_NAME' => 'RPM Specification File',
  38. 'COMMENT_SINGLE' => array(1 => '#'),
  39. 'COMMENT_MULTI' => array(),
  40. 'QUOTEMARKS' => array('"','`'),
  41. 'ESCAPE_CHAR' => '\\',
  42. 'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE,
  43. 'CASE_SENSITIVE' => array(
  44. GESHI_COMMENTS => false,
  45. ),
  46. 'KEYWORDS' => array(
  47. ),
  48. 'SYMBOLS' => array(
  49. '<', '>', '=',
  50. '!', '@', '~', '&', '|', '^',
  51. '+','-', '*', '/', '%',
  52. ',', ';', '?', '.', ':'
  53. ),
  54. 'STYLES' => array(
  55. 'KEYWORDS' => array(
  56. ),
  57. 'COMMENTS' => array(
  58. 1 => 'color: #666666; font-style: italic;',
  59. 'MULTI' => 'color: #666666; font-style: italic;'
  60. ),
  61. 'ESCAPE_CHAR' => array(
  62. 0 => 'color: #000099; font-weight: bold;',
  63. 'HARD' => 'color: #000099; font-weight: bold;'
  64. ),
  65. 'BRACKETS' => array(
  66. 0 => 'color: #009900;'
  67. ),
  68. 'STRINGS' => array(
  69. 0 => 'color: #ff0000;',
  70. ),
  71. 'NUMBERS' => array(
  72. 0 => 'color: #cc66cc;'
  73. ),
  74. 'METHODS' => array(
  75. 1 => 'color: #006600;',
  76. 2 => 'color: #006600;'
  77. ),
  78. 'SYMBOLS' => array(
  79. 0 => 'color: #339933;'
  80. ),
  81. 'REGEXPS' => array(
  82. 1 => 'color: #0000ff;',
  83. 2 => 'color: #009999;',
  84. 3 => 'color: #000000; font-weight: bold;',
  85. 4 => 'color: #ff6600; font-style: italic;',
  86. ),
  87. 'SCRIPT' => array(
  88. )
  89. ),
  90. 'REGEXPS' => array(
  91. 1 => array(
  92. // search for generic macros
  93. GESHI_SEARCH => '(%{?[a-zA-Z0-9_]+}?)',
  94. GESHI_REPLACE => '\\1',
  95. GESHI_MODIFIERS => '',
  96. GESHI_BEFORE => '',
  97. GESHI_AFTER => '',
  98. ),
  99. 2 => array(
  100. // search for special macros
  101. GESHI_SEARCH => '(%(?:define|patch\d*|mklibname|mkrel|configure\S+|makeinstall\S+|make_session|make|defattr|config|doc|setup))',
  102. GESHI_REPLACE => '\\1',
  103. GESHI_MODIFIERS => 'i',
  104. GESHI_BEFORE => '',
  105. GESHI_AFTER => '',
  106. ),
  107. 3 => array (
  108. // special definitions
  109. GESHI_SEARCH => '((?:summary|license|buildroot|buildrequires|provides|version|release|source\d*|group|buildarch|autoreqprov|provides|obsoletes|vendor|distribution|suggests|autoreq|autoprov|conflicts|name|url|requires|patch\d*):)',
  110. GESHI_REPLACE => '\\1',
  111. GESHI_MODIFIERS => 'i',
  112. GESHI_BEFORE => '',
  113. GESHI_AFTER => '',
  114. ),
  115. 4 => array (
  116. // section delimiting words
  117. GESHI_SEARCH => '(%(?:description|package|prep|build|install|clean|postun|preun|post|pre|files|changelog))',
  118. GESHI_REPLACE => '\\1',
  119. GESHI_MODIFIERS => 'i',
  120. GESHI_BEFORE => '',
  121. GESHI_AFTER => '',
  122. ),
  123. ),
  124. 'URLS' => array(),
  125. 'OOLANG' => false,
  126. 'OBJECT_SPLITTERS' => array(),
  127. 'HIGHLIGHT_STRICT_BLOCK' => array(),
  128. 'STRICT_MODE_APPLIES' => GESHI_NEVER,
  129. 'SCRIPT_DELIMITERS' => array(),
  130. );
  131. ?>