Search Results

Search found 684 results on 28 pages for 'pipeline'.

Page 14/28 | < Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >

  • Is it possible to email the contents of vim using HTML

    - by brianegge
    I like to view the current differences in the source files I'm working on with a command like: vim <(svn diff -dub) What I'd really like to be able to do is to email that colorized diff. I know vim can export HTML with the :TOhtml, but how do I pipeline this output into an html email? Ideally. i'd like to be able to send an html diff with a single shell script command.

    Read the article

  • rails assets give TypeError (can't dup NilClass)

    - by paleozogt
    I have a rails 3 app that works fine when run under rails s. However, when trying to deploy it to apache2 with fcgi, the asset pipeline breaks. For example, when trying to request /assets/logo.png the log will show: Started GET "/assets/logo.png" for 10.50.10.249 at Tue Apr 10 19:20:39 -0400 2012 TypeError (can't dup NilClass): This happens on either the production or development environments. How can I debug this?

    Read the article

  • iPad GLSL. From within a fragment shader how do I get the surface - not vertex - normal

    - by dugla
    Is it possible to access the surface normal - the normal associated with the plane of a fragment - from within a fragment shader? Or perhaps this can be done in the vertex shader? Is all knowledge of the associated geometry lost when we go down the shader pipeline or is there some clever way of recovering that information in either the vertex of fragment shader? Thanks in advance. Cheers, Doug twitter: @dugla

    Read the article

  • Http Modules are called on every request when using mvc/routing module

    - by MartinF
    I am developing a http module that hooks into the FormsAuthentication Module through the Authenticate event. While debugging i noticed that the module (and all other modules registered) gets hit every single time the client requests a resource (also when it requests images, stylesheets, javascript files (etc.)). This happens both when running on a IIS 7 server in integrated pipeline mode, and debugging through the webdev server (in non- integrated pipeline mode) As i am developing a website with a lot images which usually wont be cached by the client browser it will hit the modules a lot of unnessecary times. I am using MVC and its routing mechanishm (System.Web.Routing.UrlRoutingModule). When creating a new website the runAllManagedModulesForAllRequests attribute for the IIS 7 (system.webServer) section is per default set to true in the web.config, which as the name indicates make it call all modules for every single request. If i set the runAllManagedModulesForAllRequests attribute to false, no modules will get called. It seems that the reason for this is because of the routing module or mvc (dont know excactly why), which causes that the asp.net (aspx) handler never gets called and therefore the events and the modules never gets called (one time only like supposed). I tested this by trying to call "mydomain.com/Default.aspx" instead of just "mydomain.com/" and correctly it calls the modules only once like it is supposed. How do i fix this so it only calls the modules once when the page is requested and not also when all other resources are requested ? Is there some way i can register that all requests should fire the asp.net (aspx) handler, except requests for specific filetype extensions ? Of course that wont fix the problem if i choose to go with urls like /content/images/myimage123 for the images (without the extension). But i cant think of any other way to fix it. Is there a better way to solve this problem ? I have tried to set up an ignoreRoute like this routes.IgnoreRoute("content/{*pathInfo}"); where the content folder contains all the images, javascripts and stylesheets in seperat subfolders, but it doesnt seem to change anything. I can see there a many different possibilites when setting up a handler but I cant seem to figure out how it should be possible to setup one that will make it possible to use the routing module and have urls like /blog/post123 and not call the modules when requesting images, javascripts and stylesheets (etc.). Hope anyone out there can help me ? Martin

    Read the article

  • Multiple Headers in asp.net

    - by digiguru
    I'm running code that seems to hit the "AppendHeader" twice in the code. Response.Filter = New DeflateStream(Response.Filter, CompressionMode.Compress, True) Response.AppendHeader("Content-encoding", "deflate") ... Response.AppendHeader("Content-encoding", "deflate") I have tried using the following.... Response.Headers("Content-encoding") = "deflate" But it says This operation requires IIS integrated pipeline mode. How do I check for a headers existence, and overwrite it rather than appending it.

    Read the article

  • Does Java Spring 3.0 MVC support annotation/attribute based client side validation like Asp.net MVC

    - by Athens
    In Asp.Net MVC 2.0, at least in the beta, you could decoration your model classes with data annotation attributes and enable client side validation that leverages that criteria defined in your model data annotation attibutes. Is there anything similar for Java Spring MVC 3.0? Is it possible to inject a component into the response pipeline that can inspect the model's annotated properties and render client side validation logic to complement the server side validation logic that is invoked prior to the controller handling the request?

    Read the article

  • regular expression

    - by Jeeenda
    Hi I need a regular expression that'll give me something like this part ./something\", [something.sh from something like this string ("./something\", [something.sh", ["./something\", [something.sh"], [/* 37 vars */]) is that possible? I'm having real trouble making this since there's that \" escape sequence and also that ',' character, so I cannot simply use match everything instead of these characters. I'm working on unix so it's also possible to use pipeline of few greps or something like that. Thanks for advice.

    Read the article

  • Executing Stored Procedure for each InputRow + SSIS Script Component.

    - by Nev_Rahd
    Hello, In my Script Component, am trying to execute Stored Procedure = which return multiple rows = of which need to generate output rows. Code as below: /* Microsoft SQL Server Integration Services Script Component * Write scripts using Microsoft Visual C# 2008. * ScriptMain is the entry point class of the script.*/ using System; using System.Data; using System.Data.SqlClient; using Microsoft.SqlServer.Dts.Pipeline.Wrapper; using Microsoft.SqlServer.Dts.Runtime.Wrapper; [Microsoft.SqlServer.Dts.Pipeline.SSISScriptComponentEntryPointAttribute] public class ScriptMain : UserComponent { SqlConnection cnn = new SqlConnection(); IDTSConnectionManager100 cnManager; //string cmd; SqlCommand cmd = new SqlCommand(); public override void AcquireConnections(object Transaction) { cnManager = base.Connections.myConnection; cnn = (SqlConnection)cnManager.AcquireConnection(null); } public override void PreExecute() { base.PreExecute(); } public override void PostExecute() { base.PostExecute(); } public override void InputRows_ProcessInputRow(InputRowsBuffer Row) { while(Row.NextRow()) { DataTable dt = new DataTable(); cmd.Connection = cnn; cmd.CommandText = "OSPATTRIBUTE_GetOPNforOP"; cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add("@NK", SqlDbType.VarChar).Value = Row.OPNK.ToString(); cmd.Parameters.Add("@EDWSTARTDATE", SqlDbType.DateTime).Value = Row.EDWEFFECTIVESTARTDATETIME; SqlDataAdapter adapter = new SqlDataAdapter(cmd); adapter.Fill(dt); foreach (DataRow dtrow in dt.Rows) { OutputValidBuffer.AddRow(); OutputValidBuffer.OPNK = Row.OPNK; OutputValidBuffer.OSPTYPECODE = Row.OSPTYPECODE; OutputValidBuffer.ORGPROVTYPEDESC = Row.ORGPROVTYPEDESC; OutputValidBuffer.HEALTHSECTORCODE = Row.HEALTHSECTORCODE; OutputValidBuffer.HEALTHSECTORDESCRIPTION = Row.HEALTHSECTORDESCRIPTION; OutputValidBuffer.EDWEFFECTIVESTARTDATETIME = Row.EDWEFFECTIVESTARTDATETIME; OutputValidBuffer.EDWEFFECTIVEENDDATETIME = Row.EDWEFFECTIVEENDDATETIME; OutputValidBuffer.OPQI = Row.OPQI; OutputValidBuffer.OPNNK = dtrow[0].ToString(); OutputValidBuffer.OSPNAMETYPECODE = dtrow[1].ToString(); OutputValidBuffer.NAMETYPEDESC = dtrow[2].ToString(); OutputValidBuffer.OSPNAME = dtrow[3].ToString(); OutputValidBuffer.EDWEFFECTIVESTARTDATETIME1 = Row.EDWEFFECTIVESTARTDATETIME; OutputValidBuffer.EDWEFFECTIVEENDDATETIME1 = Row.EDWEFFECTIVEENDDATETIME; OutputValidBuffer.OPNQI = dtrow[6].ToString(); } } } public override void ReleaseConnections() { cnManager.ReleaseConnection(cnn); } } This is always skipping the first row. while(Row.NextRow()) is always bringing the second row of the input buffer. What am I doing wrong. Thanks

    Read the article

  • Using HTTP Pipelining with Jetty HTTPClient

    - by jrogi
    I'm trying to figure out how to use HTTPClient (org.eclipse.jetty.client.HttpClient) so it will pipeline HTTP Request. I've tried to create some HttpExchange instances and applying the send() method for each, in an asynchronous mode, but each HTTP request has waited for it response before the next request was sent. Can you please supply a code snippet for this case?

    Read the article

  • Performance Optimization for Matrix Rotation

    - by Summer_More_More_Tea
    Hello everyone: I'm now trapped by a performance optimization lab in the book "Computer System from a Programmer's Perspective" described as following: In a N*N matrix M, where N is multiple of 32, the rotate operation can be represented as: Transpose: interchange elements M(i,j) and M(j,i) Exchange rows: Row i is exchanged with row N-1-i A example for matrix rotation(N is 3 instead of 32 for simplicity): ------- ------- |1|2|3| |3|6|9| ------- ------- |4|5|6| after rotate is |2|5|8| ------- ------- |7|8|9| |1|4|7| ------- ------- A naive implementation is: #define RIDX(i,j,n) ((i)*(n)+(j)) void naive_rotate(int dim, pixel *src, pixel *dst) { int i, j; for (i = 0; i < dim; i++) for (j = 0; j < dim; j++) dst[RIDX(dim-1-j, i, dim)] = src[RIDX(i, j, dim)]; } I come up with an idea by inner-loop-unroll. The result is: Code Version Speed Up original 1x unrolled by 2 1.33x unrolled by 4 1.33x unrolled by 8 1.55x unrolled by 16 1.67x unrolled by 32 1.61x I also get a code snippet from pastebin.com that seems can solve this problem: void rotate(int dim, pixel *src, pixel *dst) { int stride = 32; int count = dim >> 5; src += dim - 1; int a1 = count; do { int a2 = dim; do { int a3 = stride; do { *dst++ = *src; src += dim; } while(--a3); src -= dim * stride + 1; dst += dim - stride; } while(--a2); src += dim * (stride + 1); dst -= dim * dim - stride; } while(--a1); } After carefully read the code, I think main idea of this solution is treat 32 rows as a data zone, and perform the rotating operation respectively. Speed up of this version is 1.85x, overwhelming all the loop-unroll version. Here are the questions: In the inner-loop-unroll version, why does increment slow down if the unrolling factor increase, especially change the unrolling factor from 8 to 16, which does not effect the same when switch from 4 to 8? Does the result have some relationship with depth of the CPU pipeline? If the answer is yes, could the degrade of increment reflect pipeline length? What is the probable reason for the optimization of data-zone version? It seems that there is no too much essential difference from the original naive version. EDIT: My test environment is Intel Centrino Duo processor and the verion of gcc is 4.4 Any advice will be highly appreciated! Kind regards!

    Read the article

  • How to stop PowerShell from unpacking an Enumerable object?

    - by spoon16
    Working on a simple helper function in PowerShell that takes a couple of parameters and creates a custom Enumerable object and outputs that object to the pipeline. The problem I am having is that PowerShell is always outputting a System.Array that contains the objects that are enumerated by my custom Enumerable object. How can I keep PowerShell from unpacking the Enumerable object? The code: http://gist.github.com/387768

    Read the article

  • Which parts of Graphics Pipelines are done using CPU & GPU?

    - by afriza
    Which parts of pipelines are done using CPU and which are done using GPU? Reading Wikipedia on Graphics Pipeline, maybe my question does not precisely represent what I am asking. Referring to this question, which "steps" are done in CPU and which are done in GPU? Edit: My question is more into which parts of logical high level steps needed to display terrain+3D models are using CPU/GPU instead of which functions.

    Read the article

  • How do I connect from an XPCOM object to a GStreamer plugin in a Songbird addon?

    - by utnapistim
    Hi all, I am writing a Songbird addon, with three parts: XUL (javascript), a GStreamer filter and an XPCOM addon. I am interested in accessing the GStreamer layer from my XPCOM component. If anyone knows any resources on how to do that I'd be grateful. Specifically, I need documentation or examples on accessing the GStreamer functionality from within my addon (building a GST pipeline and running a file through it, from my XPCOM component (C++). Thanks :)

    Read the article

  • BackgroundWorker Thread in IIS7 - FAIL!

    - by Darren Oster
    Just wondering if anyone has had any trouble using a BackgroundWorker Thread in a site running under IIS 7 in Integrated Pipeline mode? I am trying to use such a beast to update the database schema (admin function, obviously), and it works perfectly in Cassini, but when I deploy to IIS 7, the thread gets about one line of code in and silently ends. Is there a way to tell why a thread ended? Thanks in advance.

    Read the article

  • [PowerShell] Input encoding

    - by Andy
    Hi! I need to get output of native application under PowerShell. The problem is, output is encoded with UTF-8 (no BOM), which PowerShell does not recognize and just converts those funky UTF chars directly into Unicode. I've found PowerShell has $OutputEncoding variable, but it does not seem to affect input data. Good ol' iconv is of no help either, since this unnecessary UTF8-as-if-ASCII = Unicode conversion takes place before the next pipeline member acquires data.

    Read the article

  • How do you pipe output from a Ruby script to 'head' without getting a broken pipe error

    - by dan
    I have a simple Ruby script that looks like this require 'csv' while line = STDIN.gets array = CSV.parse_line(line) puts array[2] end But when I try using this script in a Unix pipeline like this, I get 10 lines of output, followed by an error: ruby lib/myscript.rb < data.csv | head 12080450 12080451 12080517 12081046 12081048 12081050 12081051 12081052 12081054 lib/myscript.rb:4:in `write': Broken pipe - <STDOUT> (Errno::EPIPE) Is there a way to write the Ruby script in a way that prevents the broken pipe exception from being raised?

    Read the article

  • ASP.NET Application Level vs. Session Level and Global.asax...confused

    - by contactmatt
    The following text is from the book I'm reading, 'MCTS Self-Paced Training Kit (Exam 70-515) Web Applications Development with ASP.NET 4". It gives the rundown of the Application Life Cycle. A user first makes a request for a page in your site. The request is routed to the processing pipeline, which forwards it to the ASP.NET runtime. The ASP.NET runtime creates an instance of the ApplicationManager class; this class instance represents the .NET framework domain that will be used to execute requests for your application. An application domain isolates global variables from other applications and allows each application to load and unload separately, as required. After the application domain has been created, an instance of the HostingEnvironment class is created. This class provides access to items inside the hosting environment, such as directory folders. ASP.NET creates instances of the core objects that will be used to process the request. This includes HttpContext, HttpRequest, and HttpResponse objects. ASP.NET creates an instance of the HttpApplication class (or an instance is reused). This class is also the base class for a site’s Global.asax file. You can use this class to trap events that happen when your application starts or stops. When ASP.NET creates an instance of HttpApplication, it also creates the modules configured for the application, such as the SessionStateModule. Finally, ASP.NET processes request through the HttpApplication pipleline. This pipeline also includes a set of events for validating requests, mapping URLs, accessing the cache, and more. The book then demonstrated an example of using the Global.asax file: <script runat="server"> void Application_Start(object sender, EventArgs e) { Application["UsersOnline"] = 0; } void Session_Start(object sender, EventArgs e) { Application.Lock(); Application["UsersOnline"] = (int)Application["UsersOnline"] + 1; Application.UnLock(); } void Session_End(object sender, EventArgs e) { Application.Lock(); Application["UsersOnline"] = (int)Application["UsersOnline"] - 1; Application.UnLock(); } </script> When does an application start? Whats the difference between session and application level? I'm rather confused on how this is managed. I thought that Application level classes "sat on top of" an AppDomain object, and the AppDomain contained information specific to that Session for that user. Could someone please explain how IIS manages Applicaiton level classes, and how an HttpApplication class sits under an AppDomain? Anything is appreciated.

    Read the article

  • iPhone OpenGL ES

    - by Chaoz
    Hello, Since I'm not familiar with iPhone development I'd like to know whether it is possible to use OpenGL ES1.0 on the iPhone 3gs rather than 2.0. I'd like to share a code base across different mobile platforms and not having to deal with the programmable pipeline from OGLES 2.0 could speed up an initial build. Thanks

    Read the article

  • OpenCL books/tutorials?

    - by StfnoPad
    Is there any openCL books out there? or in the pipeline? Any online openCL tutorial? I already looked at the usual pages like khronos/nvidia dev/opengl.org/ati dev/siggraph slides. Any other help or pointer is welcome :-D Thanks!

    Read the article

< Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >