Giter VIP home page Giter VIP logo

Comments (2)

travitch avatar travitch commented on June 29, 2024

diff -ur ./Config/Dyre.hs ../modified-dyre/Config/Dyre.hs
--- ./Config/Dyre.hs 2010-04-30 11:07:19.000000000 -0500
+++ ../modified-dyre/Config/Dyre.hs 2010-08-04 16:08:59.000000000 -0500
@@ -84,7 +84,7 @@
module Config.Dyre ( wrapMain, Params(..), defaultParams ) where

import System.IO ( hPutStrLn, stderr )
-import System.Directory ( doesFileExist, removeFile )
+import System.Directory ( canonicalizePath, doesFileExist, removeFile )
import System.Environment ( getArgs )

import Control.Monad ( when )
@@ -124,6 +124,8 @@
else do
-- Get the important paths
(thisBinary, tempBinary, configFile, cacheDir) <- getPaths params

  •    thisBinary' <- canonicalizePath thisBinary
    
  •    tempBinary' <- canonicalizePath tempBinary
    
     -- Check their modification times
     thisTime <- maybeModTime thisBinary
    

    @@ -150,7 +152,7 @@
    -- gone.
    errorData <- getErrorString params
    customExists <- doesFileExist tempBinary

  •    if confExists && customExists && (thisBinary /= tempBinary)
    
  •    if confExists && customExists && (thisBinary' /= tempBinary')
        then launchSub errorData tempBinary
        else enterMain errorData
    

    where launchSub errorData tempBinary = do

from dyre.

willdonnelly avatar willdonnelly commented on June 29, 2024

I understand the problem in theory, but the description of the specific setup that caused it is slightly confusing, so I haven't tested for myself that it works. But since the fix makes sense in principle and doesn't break any ordinary use patterns, it may as well be added.

Dyre v0.8.4 is uploaded to Hackage now, which contains essentially the same changes as you suggested.

At some point, it may be worthwhile to compare files based on inode number with System.Posix.Files.fileID, but since no one's complained yet, the added complexity probably isn't worth it.

from dyre.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.