1 |
On Tuesday 27 November 2012 07:26:50 justin wrote: |
2 |
> next patch for intel-sdp.eclass |
3 |
|
4 |
your code has a lot of whitespace damage (leading spaces instead of tabs). |
5 |
you should fix that up. |
6 |
|
7 |
> +# @ECLASS-FUNCTION: big-warning |
8 |
> +# @INTERNAL |
9 |
> +# warn user that we really require a license |
10 |
|
11 |
there should be @DESCRIPTION line before the description |
12 |
|
13 |
you can run /usr/portage/app-portage/eclass-manpages/files/eclass-to-manpage.sh |
14 |
against the eclass to check for errors. |
15 |
|
16 |
also, just because they're @INTERNAL doesn't mean short names like "big- |
17 |
warning" and "run-test" are OK. your eclass is putting funcs into global |
18 |
scope which can collide with other eclasses/ebuilds and possibly things in |
19 |
$PATH (dejagnu provides a standard program called `runtest`). best to give |
20 |
them a unique prefix like _isdp_big_warning(). |
21 |
|
22 |
> +_version_test() { |
23 |
> + local _comp _comp_full _arch _file _warn |
24 |
|
25 |
you've declared the vars all local. there's no need for the _ prefix. |
26 |
|
27 |
> + for ((i = 0; i < ${#_dirs[@]}; i++)); do |
28 |
|
29 |
for dir in "${dirs[@]}" ; do |
30 |
|
31 |
that avoids indexing dirs constantly |
32 |
-mike |