Posts

gitosis - What does invalid option mean when I do a git push? -

i have set own git server gitosis. seems functioning correctly when git push error message counting objects: 5, done. delta compression using 2 threads. compressing objects: 100% (3/3), done. writing objects: 100% (3/3), 388 bytes, done. total 3 (delta 0), reused 0 (delta 0) : invalid optione: line 2: set: - set: usage: set [--abefhkmnptuvxbchp] [-o option-name] [arg ...] ssh://git@mytestserver/~/repositories/gitosis-admin.git a subsequent pull work , seems correctly merge. ideas? that error coming shell on remote system (bash likely). login shell on remote system trying execute source file (like ~/.profile) broken. be, example, user's shell /bin/bash somewhere in git or execution path ssh invoking, calling /bin/sh instead (which might older less options).

java - Load Balancing webservers using Httpurlconnection on client side -

my application needs connect web service xml data. have 4 web service endpoints. what best way load balance between web service? i know best way use hardware/software load balancer have on client side. i have develop client using httpurlconnection working fine 1 end point. i planning use hashmap url's , after call 1 one. regards, imran without central point co-ordinate distribution of connections between service endpoints, you're pretty limited choosing arbitrary one-of-four each time establish connection. reasonable approach may use each endpoint in turn successive interactions client (starting 1 chosen @ random ensure there isn't heavy bias towards single endpoint @ times when clients may restarted). alternatively, implement endpoint returns preferred connection, client make subsequent calls. implementation assign clients round robin style, or reference load reported each endpoint @ given time. of 2 approaches, former far simpler , should give r...

java get the longest string in enum -

i find longest string within java enum. best way this? havent been working enums suggestion welcome. these enums public enum domain_languages { eng, swe; public static list<domain_languages> getdomainlanguages(){ list<domain_languages> languages = new arraylist<domain_languages>(); languages.add(eng); languages.add(swe); return languages; } } public enum domain_state { live, pending_renewal, pending_transfer_out, } edit: i didnt define question , hence edit it. whant 2 enums function takes of 2 kind of enums have defined , finds longest literal. in domain_state "pending_transfer_out". hope makes things bit easier understand. edit 2 so i'v gotten som has been great, im not sure why code not work. complains when try use enumlist.values()? reason couldnt find solution in first place, missing? =) public string calculatedropdownlistwidth(enum enumlist){ int chars = 0; ...

flex - Style of tabulation : replace spaces by dots -

multiple choice questions, format text : answer............................a longanswer....................b veryveryveryverylong answer............................c (display in richtext or label) data come xml : <answer_a>answer</answer_a> <answer_b>longanswer</answer_b> ... i tried 3 labels in horizontal layout each lines doesn't work third case. now use tabstops alignment, work well, can't find how replace spaces dots in proper way. hum, interesting problem. personally, think put answers in datagroup item renderer show answer right , answer label left, overriding updatedisplaylist function, draw points (1 pixel 'squares') leftmost text rightmost. however, third possibility, lot more difficult achieve. can't think of way right now.

javascript - Dynamic Navigation bar (with images) with jquery and php - problems with mouseover effects -

i'm building dynamic navigation bar controlled php, , i'm using images within list. , i'm applying jquery 'hover' effects. php code: $path = $_server['php_self']; $page = basename($path); $page = basename($path, '.php'); and in navigation list i'm setting 'display:none' , 'display:inline' depending on return value of $page using php 'if' statement. see code: <ul id="cssdropdown"> <li class="headlink"> <a class="lightnav" href="index.php" <?php if($page == 'index'){echo "style='display:none !important'";}else{echo "style='display:inline'";}?>><img src="images/navbuttons/home.png" /></a> <a class="darknav" href="index.php" <?php if($page == 'index'){echo "style='display:inline !important'";}else{echo "style='display:none...

delphi - Connection timed out when trying to TidSMTP.Connect -

trying connect gmail smtp server fails. it hangs there ~20 seconds , throws error "socket error #10060 connection timed out". i've tried copy , paste post , doesn't work also. procedure tform1.btn1click(sender: tobject); var email : tidmessage; idsmtpgmail: tidsmtp; idsslgmail : tidssliohandlersocketopenssl; begin idsslgmail := tidssliohandlersocketopenssl.create(nil); idsslgmail.ssloptions.method := sslvtlsv1; idsslgmail.ssloptions.mode := sslmunassigned; idsmtpgmail := tidsmtp.create(nil); idsmtpgmail.iohandler := idsslgmail; idsmtpgmail.usetls := utuseexplicittls; email := tidmessage.create(nil); email.from.address := 'from'; email.recipients.emailaddresses := 'recipient'; email.subject := 'test subject'; email.body.text := 'test body'; idsmtpgmail.host := ...

.net - Efficiently persisting calendar data with Entity Framework? -

i working on school project involves managing driving instructor calendars. the application stores time periods on instructor available. public partial class availabilityperiod // kind of pseudo code { instructor instructor; datetime start; datetime end; } it stores individual appointments instructor, in similar fashion. when customer says, example, "i want 2-hour lesson", have fetch availability periods , appointements of instructors in order compute "actual availability" , find having more 2 hours free in his/her schedule. is there better way ? my question exact duplicate of time calendar data structure , know it. but, well... we're in 2011 , i'm interested in entity framework-specific info, or @ least doing whith object relational mapping :-) i wrote similar scheduling application, , ended taking little different approach (though approach work). in system, schedule broken down 15 minute increments, called blocks, , store...