Considering the maintenance of this is at minimum typing "drush features-update foo" and at maximum copying/pasting some code, it seems relatively minor. Views export/import expects these parameters, so I don't recommend changing them.<div>
<br></div><div>Specific questions/issues like this are better suited for the Views issue queue, but I don't think this particular question has much traction. It's not a bug, nor affects performance (especially not with an opcode cache). It's a question of personal preference and semantics, some of which you may have to abandon when leveraging Drupal. ;)</div>
<div><div>
<br><br><div class="gmail_quote">On Fri, Mar 18, 2011 at 9:54 AM, Sean Dague <span dir="ltr"><<a href="mailto:sean@dague.net">sean@dague.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
For instance, I find large duplication of:<br>
<br>
'alter' => array(<br>
'alter_text' => 0,<br>
'text' => '',<br>
'make_link' => 0,<br>
'path' => '',<br>
'link_class' => '',<br>
'alt' => '',<br>
'prefix' => '',<br>
'suffix' => '',<br>
'target' => '',<br>
'help' => '',<br>
'trim' => 0,<br>
'max_length' => '',<br>
'word_boundary' => 1,<br>
'ellipsis' => 1,<br>
'html' => 0,<br>
'strip_tags' => 0,<br>
),<br>
<br>
all throughout the export to be not conducive to maintainability (there are 12 instances of that stanza, 9 are exactly the same, and the other 3 only vary in their 'text' field).<br>
<br>
I find that level of duplication somewhat problematic, and something I like to avoid.<br><font color="#888888">
<br>
-Sean</font><div class="im"><br>
<br>
On 03/18/2011 09:31 AM, Carl Wiedemann wrote:<br>
</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
Not quite sure I understand what exactly is non-maintainable?<br>
<br>
You may also investigate <a href="http://drupal.org/project/features" target="_blank">http://drupal.org/project/features</a> for<br>
assistance with exporting Views to code.<br>
<br>
<br>
On Fri, Mar 18, 2011 at 7:45 AM, Sean Dague <<a href="mailto:sean@dague.net" target="_blank">sean@dague.net</a><br></div><div class="im">
<mailto:<a href="mailto:sean@dague.net" target="_blank">sean@dague.net</a>>> wrote:<br>
<br>
I'm working on a new drupal 6.x module (currently in sandbox<br>
awaiting review - <a href="http://drupal.org/sandbox/sdague/1072704" target="_blank">http://drupal.org/sandbox/sdague/1072704</a>) which<br>
exports it's data via views. When I implemented<br>
hook_views_default_views() I just used the export functionality on<br>
views for a few basic views to get things started.<br>
<br>
That works, but those are both very verbose, and don't implement any<br>
i18n. Is there a standard way of trimming down the default values in<br>
those views so this becomes a bit more sane and maintainable?<br>
<br>
Advice would be appreciated,<br>
<br>
-Sean<br>
<br>
--<br>
<br>
Sean Dague Learn about the Universe with the<br>
sean at dague dot net Mid-Hudson Astronomical Association<br>
<a href="http://dague.net" target="_blank">http://dague.net</a> <a href="http://midhudsonastro.org" target="_blank">http://midhudsonastro.org</a><br>
<br>
<br>
</div></blockquote><div><div></div><div class="h5">
<br>
<br>
-- <br>
<br>
Sean Dague Learn about the Universe with the<br>
sean at dague dot net Mid-Hudson Astronomical Association<br>
<a href="http://dague.net" target="_blank">http://dague.net</a> <a href="http://midhudsonastro.org" target="_blank">http://midhudsonastro.org</a><br>
</div></div></blockquote></div><br></div></div>