
538 S.W.2d 782 (1976)
Ex parte David Earl JASPER and Donald Wayne Broussard.
No. 52026.
Court of Criminal Appeals of Texas.
July 14, 1976.
*783 David Earl Jasper and Donald Wayne Broussard, petitioners pro se.
Tom Hanna, Dist. Atty., Beaumont, Jim D. Vollers, State's Atty., David S. McAngus, Asst. State's Atty., Austin, for the State.

OPINION
DOUGLAS, Judge.
This is a post conviction habeas corpus proceeding where petitioners are asking for joint relief pursuant to Article 11.07, V.A.C. C.P.
Both petitioners entered pleas of guilty to three indictments charging them with robbery by firearms, as co-defendants, and were each assessed three fifteen year concurrent prison sentences on September 9, 1974.
The petitioners filed for a writ of habeas corpus in the convicting court, alleging that the State refused to comply with its plea bargaining agreement with them at the time of the trial by not fulfilling a promise that they would receive "good time" credit for time spent in jail prior to their Texas convictions while they were still serving sentences in Louisiana. The trial court, after considering the documentary evidence presented, made the following findings of fact and conclusions of law, to-wit:
(1) During the first week of February, 1970, the petitioners participated jointly in three armed robberies in Jefferson County, Texas. They were not arrested at that time.
(2) According to the petitioners' pleadings, they were subsequently arrested in Lake Charles, Louisiana, sometime later in February, 1970, for offenses committed in Louisiana.
(3) On March 12, 1970, petitioners were indicted in Cause No. 28192 by the Jefferson County Grand Jury for the offense of robbery by firearms. Subsequently, two more indictments in Cause Nos. 28,200 and 28,201 were returned on March 19, 1970, for similar offenses.
(4) On March 19, 1970, the sheriff's office of Jefferson County placed a detainer or "hold" against the petitioners while they were in the Lake Charles, Louisiana jail, such detainers being based upon the Jefferson County indictments.
(5) The petitioners were subsequently convicted for offenses committed in the state of Louisiana in July, 1970, and were sentenced to ten-year terms of imprisonment in that state. The petitioners remained in confinement in Louisiana until some time in 1974, at which time they were returned for trial in Jefferson County.
(6) Subsequently, the plea bargaining negotiations were conducted between petitioners and the prosecution, at which time the prosecution recommended to the court that, in exchange for the three guilty pleas by both defendants, the petitioners be assessed three fifteen-year sentences, each to run concurrently, and each to be credited with full back jail time credits for all time spent during the petitioners' prior incarceration in the Louisiana State Penitentiary.
The above-mentioned plea bargaining agreement was approved by the defense and the trial court, and the three fifteen-year sentences were assessed, but at the time of the sentencing, the trial court neglected to award the petitioners with full credit for time spent in the Louisiana State Penitentiary.
The State's prosecutor in these cases, the Honorable Danny Doyle, provided an affidavit to the court saying that he was in charge of the cases against the petitioners, and that this was the plea bargaining arrangement worked out between the State and the defense.
*784 The prosecutor's affidavit specifically rebuts the petitioners' allegation that the prosecution promised them credit for "good time" previously served toward the Louisiana convictions. We do not feel that a further evidentiary hearing is required in this case. The affidavit is sufficient to rebut the petitioners' allegations. The hearing judge had sufficient evidence before him to find the allegations concerning good time credit are not true.
The hearing judge found that, as a result of the plea bargaining agreement by the State, the petitioners should have been granted all back jail time credits served in the Louisiana State Penitentiary under the state's convictions toward the discharge of the Texas sentence. While the trial court did feel that the petitioners were entitled to this "flat time" jail credit, he denied the petitioners' request for any "good time" credit served during the petitioners' incarceration in the state of Louisiana.
The hearing court had sufficient evidence to conclude that petitioners are entitled to credit for time spent in jail in Louisiana toward the discharge of their Texas sentences. Pursuant to the State's plea bargaining agreement, and the trial court's finding that this agreement was approved by the court at the time of the trials, the petitioners would be entitled to such credit as a matter of due process of law. See Santobello v. New York, 404 U.S. 257, 92 S.Ct. 495, 30 L.Ed.2d 427 (1971). Compare Ex parte Shuflin, 528 S.W.2d 610 (Tex.Cr. App.1975); Cruz v. State, 530 S.W.2d 817 (Tex.Cr.App.1975); Gibson v. State, 532 S.W.2d 69 (Tex.Cr.App.1975); Rodriquez v. State, 509 S.W.2d 319 (Tex.Cr.App.1974).
Also, petitioners would be entitled to this jail time credit under the mandatory provisions of Article 42.03, Section 2, V.A.C.C.P., effective August 27, 1973, which reads as follows:
"Sec. 2. In all criminal cases the judge of the court in which the defendant was convicted shall give the defendant credit on his sentence for the time that the defendant has spent in jail in said cause, from the time of his arrest and confinement until his sentence by the trial court." (Emphasis added)
In the case at bar, the trial court found that the petitioners are entitled to all credit for time spent while in the Louisiana State Penitentiary; however, the records reflect that the State of Texas placed its detainer on the petitioners for these robbery cases on March 19, 1970, which was prior to their convictions and commitments to the Louisiana State Penitentiary. Under these circumstances, the petitioners are entitled to credit for flat time spent in custody in Louisiana from March 19, 1970, until the present date. See Harrelson v. State, 511 S.W.2d 957 (Tex.Cr.App.1974); Ex parte Alvarez, 519 S.W.2d 440 (Tex.Cr.App. 1975); Ex parte Spates, 521 S.W.2d 265 (Tex.Cr.App.1975). Once the Texas detainer was filed against the petitioners in Louisiana, the petitioners were in "constructive custody" of the State of Texas and therefore, since the petitioners were sentenced after the effective date of the amendment of Article 42.03, supra, the petitioners are entitled to flat time credit for the time spent in custody, even in the state of Louisiana, from March 19, 1970, until the present date.[1] See also Article 42.09, Sections 2 and 6, V.A.C.C.P.
The petitioners have alleged that the State promised them "good time" credit pursuant to Article 6184l, V.A.C.S., toward the discharge of their Texas sentence for time spent while in confinement in the state of Louisiana. The trial judge found that no such promises were made and he has recommended that petitioners' request for "good time" credit be denied. We hold that the petitioners are entitled to good time, as a matter of law, under the authority of Article 42.03, Section 4, V.A.C.C.P., as amended on August 27, 1973, which reads as follows:
*785 "Sec. 4. When a defendant who has been sentenced to imprisonment in the Department of Corrections has spent time in jail pending trial and sentence or pending appeal, the judge of the sentencing court shall direct the sheriff to attach to the commitment papers a statement assessing the defendant's conduct while in jail. On the basis of the statement, the Department of Corrections shall grant the defendant such credit for good behavior for the time spent in jail as he would have earned had he been in the custody of the department." (Emphasis added)
Under this provision of the amended Code of Criminal Procedure, the Legislature has clearly indicated its desire to provide criminal defendants with credit not only for time spent in jail pending appeal, see e.g., Pruett v. Texas, 470 F.2d 1182 (5th Cir. 1973), but also for all good time credit spent in custody prior to trial and sentence. Therefore, criminal defendants sentenced after August 27, 1973, must be credited with all calendar time credit for all days spent in custody prior to trial and pending appeal, and that in addition, these defendants would also be entitled to consideration for "good time" credits provided under article 6184l, supra, as the Texas Department of Corrections might award for the time spent in custody.
In the case at bar the State of Texas placed its detainer upon the petitioners on March 19, 1970; therefore, since the petitioners were in "constructive custody" of the State from that day forward, they were entitled also to consideration by the Texas Department of Corrections for good time credits under Article 6184l, supra. See Ex parte Enriquez, 490 S.W.2d 546 (Tex.Cr. App.1973); Ex parte Bennett, 508 S.W.2d 646 (Tex.Cr.App.1974); Ex parte Esquivel, 531 S.W.2d 339 (Tex.Cr.App.1976); Ex parte Spates, supra; Harrelson v. State, supra; Article 42.09, Sections 2 and 6, supra.
For the reasons stated above, the petitioners are entitled to flat time credit toward the discharge of their Texas sentences from March 19, 1970, as well as consideration for "good time" credits which may be awarded pursuant to the rules and regulations of the administration of the Texas Department of Corrections' disciplinary system. The record before this Court does not reflect whether the petitioners maintained a good conduct record while in the Louisiana State Penitentiary. The Texas Department of Corrections' officials may ascertain from the officials of the Louisiana State Penitentiary whatever is required to determine the petitioners' conduct record. Then, the Texas Department of Corrections' officials can make whatever decisions are appropriate in awarding the petitioners with good conduct credit, if any, based upon the records from the Louisiana State Penitentiary.
The relief sought is granted in part. A copy of this opinion will be delivered to the Texas Department of Corrections.
It is so ordered.
NOTES
[1]  The records reflect that the petitioners have been in continuous custody for this entire time and that on several occasions sought to obtain a fast and speedy trial in the State of Texas. The petitioners cannot be penalized for not being brought to trial. Compare Ex parte Iglehart, 535 S.W.2d 185 (Tex.Cr.App.1976).
