File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -112,8 +112,23 @@ defmodule Standalone do
112112 File . mkdir_p! ( release_archives_dir )
113113
114114 hex_version = Keyword . fetch! ( Application . spec ( :hex ) , :vsn )
115- source_hex_path = Path . join ( Mix . path_for ( :archives ) , "hex-#{ hex_version } -otp-#{ System . otp_release ( ) } " )
116- release_hex_path = Path . join ( release_archives_dir , "hex-#{ hex_version } -otp-#{ System . otp_release ( ) } " )
115+
116+ source_hex_path =
117+ Path . join ( Mix . path_for ( :archives ) , "hex-#{ hex_version } -otp-#{ System . otp_release ( ) } " )
118+
119+ # TODO: Handling both paths for now, need to investigate why this broke.
120+ source_hex_path =
121+ if File . exists? ( source_hex_path ) do
122+ source_hex_path
123+ else
124+ path = Path . join ( Mix . path_for ( :archives ) , "hex-#{ hex_version } " )
125+ Mix . shell ( ) . info ( "warning: #{ source_hex_path } not found" )
126+ path
127+ end
128+
129+ release_hex_path =
130+ Path . join ( release_archives_dir , "hex-#{ hex_version } -otp-#{ System . otp_release ( ) } " )
131+
117132 cp_r! ( source_hex_path , release_hex_path )
118133
119134 release
You can’t perform that action at this time.
0 commit comments