search for: random8

Displaying 20 results from an estimated 56 matches for "random8".

Did you mean: random
2009 May 27
12
query on Ruby array
Looking for suggestions on following two queries. Query 1 ------------------------------ Are the two following lines of code different in Ruby / Rails ( in a *.html.erb) file. <% if @forms.count != 0 %> <!-- first code --> Vs. <% if @forms.count %> <!--second code --> @forms is an array of objects. Coming from "C" language development background, i thought
2015 Oct 07
1
Re: [PATCH 5/5] mllib: Replace various ad hoc string_* functions with String.*
...string_prefix -> String.is_prefix > string_suffix -> String.is_suffix > string_find -> String.find > replace_str -> String.replace > string_nsplit -> String.nsplit > string_split -> String.split > string_lines_split -> String.lines_split > string_random8 -> String.random8 > --- As mentioned yesterday on IRC, I'm torn about this one: the functions would automatically alias functions with the same name, whenever available in OCaml' stdlib. Also (but this is more personal), reading String.foo would make me think that it is part of the...
2016 Dec 07
0
[PATCH v3 2/6] v2v: ova: don't detect compressed disks, read the OVF instead
...,17 +289,16 @@ object (* The spec allows the file to be gzip-compressed, in which case * we must uncompress it into the tmpdir. *) - let filename = - if detect_file_type filename = `GZip then ( - let new_filename = tmpdir // String.random8 () ^ ".vmdk" in - let cmd = - sprintf "zcat %s > %s" (quote filename) (quote new_filename) in - if shell_command cmd <> 0 then - error (f_"error uncompressing %s, see earlier error messages") -...
2016 Nov 12
0
[PATCH v2 2/5] v2v: ova: don't detect compressed disks, read the OVF instead
...th + | None | Some "identity" -> false + | Some "gzip" -> true + | Some s -> error (f_"unsupported comprression in OVF: %s") s in + + let filename = if compressed then ( + let new_filename = tmpdir // String.random8 () ^ ".vmdk" in + let cmd = + sprintf "zcat %s > %s" (quote ovf_folder // filename) (quote new_filename) in + if shell_command cmd <> 0 then + error (f_"error uncompressing %s, see earlier error messages") +...
2009 May 05
4
modalbox rails var interpolation
Howdy everyone. I am using modalbox which is very nice an easy to use. I have this for an edit for a company listing: <td><%= link_to(''Manage Companies'', {}, :onclick => ''Modalbox.show(\''/ companies/edit/#{company.id}\'', {width: 600}); return false;'') %></td> The link is not putting the company.id in it puts #{
2016 Nov 21
2
Re: [PATCH v2 2/5] v2v: ova: don't detect compressed disks, read the OVF instead
...ssion in OVF: %s") s in Typo here, "compression". Also, the two "expr" and "compressed" let could be isolated in the "let filename" block. > + > + let filename = if compressed then ( > + let new_filename = tmpdir // String.random8 () ^ ".vmdk" in > + let cmd = > + sprintf "zcat %s > %s" (quote ovf_folder // filename) (quote new_filename) in > + if shell_command cmd <> 0 then > + error (f_"error uncompressing %s, see earlier error me...
2009 May 25
4
after_create and has_one association bug?
Hello, I''ve come across an issue that I''m sure is a bug when using after_create with a has_one association, but I''m not 100% certain if I''m missing something. This is pretty much exactly the code I''m using. Two simple classes (Account and Contact) and I create the contact after I create an account (via after_create). I''m not passing in a
2015 Nov 04
1
[PATCH 0/1] sparsify: Let --in-place capture ^C and shut down gracefully
This patch is easier to read if you use the 'git show -w' option. Also observe that: fun a -> ( fun () -> (* code *) ) (ie. returning a closure) is identical to: fun a () -> (* code *) Rich.
2009 May 27
9
Contingent Select Boxes - 2 Q's
I have a form with contingent select boxes (the state is contingent on the country selected, so when the country selected changes, the state changes -- I am using the Carmen plugin for getting my state names and country names together, but not the functionality I am interested in achieving). Everything works fine except I cannot figure out how to amend my code such that: A. When the form is first
2010 May 05
6
form remote tag :before=> function problem
Hi I have a strange problem, I am using the below code form_remote_tag :url => ''/abc/test'',:before => "return hello();", :update=>''test_categories'' ,:complete => "Element.hide(''spinner'')", :loading => "Element.show(''spinner'')" do I am using :before=> function to validate the
2015 Oct 06
0
[PATCH 5/5] mllib: Replace various ad hoc string_* functions with String.*
...vs "new" functions are: string_prefix -> String.is_prefix string_suffix -> String.is_suffix string_find -> String.find replace_str -> String.replace string_nsplit -> String.nsplit string_split -> String.split string_lines_split -> String.lines_split string_random8 -> String.random8 --- builder/checksums.ml | 2 +- builder/downloader.ml | 2 +- builder/index_parser.ml | 4 +- builder/paths.ml | 2 +- builder/sigchecker.ml | 12 +- customize/cus...
2016 Nov 12
0
[PATCH v2 4/5] v2v: ova: don't extract files from OVA if it's not needed
...e disk actual mode disk expected; @@ -283,25 +389,50 @@ object | Some "gzip" -> true | Some s -> error (f_"unsupported comprression in OVF: %s") s in - let filename = if compressed then ( - let new_filename = tmpdir // String.random8 () ^ ".vmdk" in - let cmd = - sprintf "zcat %s > %s" (quote ovf_folder // filename) (quote new_filename) in - if shell_command cmd <> 0 then - error (f_"error uncompressing %s, see earlier error messages") -...
2020 Aug 07
3
[PATCH nbdkit] file: Implement cache=none and fadvise=normal|random|sequential.
You can use these flags as described in the manual page to optimize access patterns, and to get better behaviour with the page cache in some scenarios. For my testing I used the cachedel and cachestats utilities written by Julius Plenz (https://github.com/Feh/nocache). I started with a 32 GB file of random data on a machine with about 32 GB of RAM. At the beginning of the test I evicted the
2015 Oct 06
10
[PATCH 0/5] mllib: Hide bad String functions and miscellaneous refactoring.
Hide/prevent the use of bad string functions like String.lowercase. These are replaced by safe functions that won't break UTF-8 strings. Other miscellaneous refactoring. Rich.
2016 Nov 12
9
[PATCH v2 0/5] Import directly from OVA tar archive if possible
This series is related to the problem of inefficient import of OVA files. The needed enhancements of QEMU were merged into the codebase and should be available in QEMU 2.8. From there we can use 'size' and 'offset' options in raw driver to tell QEMU to use only subset of a file as an image. The patch set is more or less complete. The only outstanding issue is the missing detection
2009 May 25
1
Passing a JavaScript variable through a Rails params hash
Hi guys, hoping someone can give me a pointer with this? I have a Javascript variable that I''m updating dynamically as a user interacts with the page. I want the user to be able to save it''s value at any time along with some text data in a pop-up form, so the best way I can think of is to pass it through the params hash without writing it into the form. I''m not totally
2009 May 25
2
CAn u please tell wats the prob in runnning my project?
[~/kallori]# rake db:migrate (in /home/gm/kallori) no such file to load -- hmac-sha1 /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require'' /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require'' /home/gm/kallori/vendor/rails/activesupport/lib/active_support/ dependencies.rb:510:in `require''
2009 Feb 05
1
Need the activerecord-sqlserver-adapter but...
Hi... I am new to RoR development, and Web development in general (but have about 25 years of IT/software experience - just not in the Web area)... I have a really good RoR 2.X book that I have read and reread a few times and starting to try to apply what I read... Have a Web app that I need to write at work, and prove to folks that RoR is THE_WAY, despite their ASP .NET protests otherwise... So,
2009 Feb 15
2
Collapsible Fieldset
Hey there, (First steps in Ruby and Rails...) I''m trying to make a fieldset collapsible, like they are, for example, on many Drupal pages. What I''ve figuared out is the following: <fieldset id="addressdata" class="collapsible collapsed"> <legend> <%= link_to_function("Show/Hide Addressdata") { |page| page[:
2009 Jan 28
3
Apply style in collection_select ?????
Hi to all, i have this snip i want to apply style to this combo but there is no effect help....... <%= collection_select(:customer,:country_id, @countries,:id, :country, html_options={ "style" => "width:110px" },:onchange => ''updateState('''');'',:id =>''country_id'' )%> Thanks, -- Posted via